码迷,mamicode.com
首页 > 编程语言 > 详细

java.io.IOException: 您的主机中的软件中止了一个已建立的连接。

时间:2015-06-15 20:31:36      阅读:259      评论:0      收藏:0      [点我收藏+]

标签:android

1、错误描述

[2015-06-15 19:13:48 - ddmlib] 您的主机中的软件中止了一个已建立的连接。
java.io.IOException: 您的主机中的软件中止了一个已建立的连接。
	at sun.nio.ch.SocketDispatcher.write0(Native Method)
	at sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:51)
	at sun.nio.ch.IOUtil.writeFromNativeBuffer(IOUtil.java:93)
	at sun.nio.ch.IOUtil.write(IOUtil.java:65)
	at sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:487)
	at com.android.ddmlib.JdwpPacket.writeAndConsume(JdwpPacket.java:213)
	at com.android.ddmlib.Client.sendAndConsume(Client.java:675)
	at com.android.ddmlib.HandleHeap.sendREAQ(HandleHeap.java:342)
	at com.android.ddmlib.Client.requestAllocationStatus(Client.java:521)
	at com.android.ddmlib.DeviceMonitor.createClient(DeviceMonitor.java:831)
	at com.android.ddmlib.DeviceMonitor.openClient(DeviceMonitor.java:799)
	at com.android.ddmlib.DeviceMonitor.processIncomingJdwpData(DeviceMonitor.java:759)
	at com.android.ddmlib.DeviceMonitor.deviceClientMonitorLoop(DeviceMonitor.java:648)
	at com.android.ddmlib.DeviceMonitor.access$100(DeviceMonitor.java:44)
	at com.android.ddmlib.DeviceMonitor$3.run(DeviceMonitor.java:576)

[2015-06-15 19:13:49 - ddmlib] 您的主机中的软件中止了一个已建立的连接。
java.io.IOException: 您的主机中的软件中止了一个已建立的连接。
	at sun.nio.ch.SocketDispatcher.write0(Native Method)
	at sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:51)
	at sun.nio.ch.IOUtil.writeFromNativeBuffer(IOUtil.java:93)
	at sun.nio.ch.IOUtil.write(IOUtil.java:65)
	at sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:487)
	at com.android.ddmlib.JdwpPacket.writeAndConsume(JdwpPacket.java:213)
	at com.android.ddmlib.Client.sendAndConsume(Client.java:675)
	at com.android.ddmlib.HandleHeap.sendREAQ(HandleHeap.java:342)
	at com.android.ddmlib.Client.requestAllocationStatus(Client.java:521)
	at com.android.ddmlib.DeviceMonitor.createClient(DeviceMonitor.java:831)
	at com.android.ddmlib.DeviceMonitor.openClient(DeviceMonitor.java:799)
	at com.android.ddmlib.DeviceMonitor.processIncomingJdwpData(DeviceMonitor.java:759)
	at com.android.ddmlib.DeviceMonitor.deviceClientMonitorLoop(DeviceMonitor.java:648)
	at com.android.ddmlib.DeviceMonitor.access$100(DeviceMonitor.java:44)
	at com.android.ddmlib.DeviceMonitor$3.run(DeviceMonitor.java:576)

[2015-06-15 19:13:58 - ddmlib] 您的主机中的软件中止了一个已建立的连接。
java.io.IOException: 您的主机中的软件中止了一个已建立的连接。
	at sun.nio.ch.SocketDispatcher.write0(Native Method)
	at sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:51)
	at sun.nio.ch.IOUtil.writeFromNativeBuffer(IOUtil.java:93)
	at sun.nio.ch.IOUtil.write(IOUtil.java:65)
	at sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:487)
	at com.android.ddmlib.JdwpPacket.writeAndConsume(JdwpPacket.java:213)
	at com.android.ddmlib.Client.sendAndConsume(Client.java:675)
	at com.android.ddmlib.HandleHeap.sendREAQ(HandleHeap.java:342)
	at com.android.ddmlib.Client.requestAllocationStatus(Client.java:521)
	at com.android.ddmlib.DeviceMonitor.createClient(DeviceMonitor.java:831)
	at com.android.ddmlib.DeviceMonitor.openClient(DeviceMonitor.java:799)
	at com.android.ddmlib.DeviceMonitor.processIncomingJdwpData(DeviceMonitor.java:759)
	at com.android.ddmlib.DeviceMonitor.deviceClientMonitorLoop(DeviceMonitor.java:648)
	at com.android.ddmlib.DeviceMonitor.access$100(DeviceMonitor.java:44)
	at com.android.ddmlib.DeviceMonitor$3.run(DeviceMonitor.java:576)

[2015-06-15 19:13:59 - ddmlib] 您的主机中的软件中止了一个已建立的连接。
java.io.IOException: 您的主机中的软件中止了一个已建立的连接。
	at sun.nio.ch.SocketDispatcher.write0(Native Method)
	at sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:51)
	at sun.nio.ch.IOUtil.writeFromNativeBuffer(IOUtil.java:93)
	at sun.nio.ch.IOUtil.write(IOUtil.java:65)
	at sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:487)
	at com.android.ddmlib.JdwpPacket.writeAndConsume(JdwpPacket.java:213)
	at com.android.ddmlib.Client.sendAndConsume(Client.java:675)
	at com.android.ddmlib.HandleHeap.sendREAQ(HandleHeap.java:342)
	at com.android.ddmlib.Client.requestAllocationStatus(Client.java:521)
	at com.android.ddmlib.DeviceMonitor.createClient(DeviceMonitor.java:831)
	at com.android.ddmlib.DeviceMonitor.openClient(DeviceMonitor.java:799)
	at com.android.ddmlib.DeviceMonitor.processIncomingJdwpData(DeviceMonitor.java:759)
	at com.android.ddmlib.DeviceMonitor.deviceClientMonitorLoop(DeviceMonitor.java:648)
	at com.android.ddmlib.DeviceMonitor.access$100(DeviceMonitor.java:44)
	at com.android.ddmlib.DeviceMonitor$3.run(DeviceMonitor.java:576)

[2015-06-15 19:41:57 - DeviceMonitor] Adb connection Error:远程主机强迫关闭了一个现有的连接。
[2015-06-15 19:41:58 - DeviceMonitor] Connection attempts: 1
[2015-06-15 19:42:00 - DeviceMonitor] Connection attempts: 2
[2015-06-15 19:42:02 - DeviceMonitor] Connection attempts: 3
[2015-06-15 19:42:04 - DeviceMonitor] Connection attempts: 4
[2015-06-15 19:42:06 - DeviceMonitor] Connection attempts: 5
[2015-06-15 19:42:08 - DeviceMonitor] Connection attempts: 6
[2015-06-15 19:42:10 - DeviceMonitor] Connection attempts: 7
[2015-06-15 19:42:12 - DeviceMonitor] Connection attempts: 8
[2015-06-15 19:42:14 - DeviceMonitor] Connection attempts: 9
[2015-06-15 19:42:16 - DeviceMonitor] Connection attempts: 10
[2015-06-15 19:42:18 - DeviceMonitor] Connection attempts: 11

2、错误原因

        我在Eclipse和Android Studio都是用的同一个SDK,在Android Studio上运行Android项目,这时Eclipse也是打开的,导致adt.exe在两个软件同事运行,导致出错


3、解决办法

      关闭其中一个软件,只准一个运行

java.io.IOException: 您的主机中的软件中止了一个已建立的连接。

标签:android

原文地址:http://blog.csdn.net/you23hai45/article/details/46507051

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!