为了账号安全,请及时绑定邮箱和手机立即绑定

亲们,你们遇到过java.net.SocketException: Connection reset问题吗?求解决方法

服务器已经启动!

java.net.SocketException: Connection reset

at java.net.SocketInputStream.read(Unknown Source)

at java.net.SocketInputStream.read(Unknown Source)

at java.io.ObjectInputStream$PeekInputStream.read(Unknown Source)

at java.io.ObjectInputStream$PeekInputStream.readFully(Unknown Source)

at java.io.ObjectInputStream$BlockDataInputStream.readShort(Unknown Source)

at java.io.ObjectInputStream.readStreamHeader(Unknown Source)

at java.io.ObjectInputStream.<init>(Unknown Source)

at com.xk.ServerThread.run(ServerThread.java:21)

java.net.SocketException: Connection reset by peer: socket write error

at java.net.SocketOutputStream.socketWrite0(Native Method)

at java.net.SocketOutputStream.socketWrite(Unknown Source)

at java.net.SocketOutputStream.write(Unknown Source)

at java.io.ObjectOutputStream$BlockDataOutputStream.drain(Unknown Source)

at java.io.ObjectOutputStream$BlockDataOutputStream.setBlockDataMode(Unknown Source)

at java.io.ObjectOutputStream.<init>(Unknown Source)

at com.xk.ServerThread.run(ServerThread.java:22)

ServerThread.java:22的代码如下

ois = new ObjectInputStream(socket.getInputStream()); //对象输入流

正在回答

举报

0/150
提交
取消

亲们,你们遇到过java.net.SocketException: Connection reset问题吗?求解决方法

我要回答 关注问题
意见反馈 帮助中心 APP下载
官方微信