作者: dubei1993 时间: 2016-6-9 22:51
Exception in thread "main" java.net.SocketException: Connection reset
at java.net.SocketInputStream.read(Unknown Source)
at java.net.SocketInputStream.read(Unknown Source)
at sun.nio.cs.StreamDecoder.readBytes(Unknown Source)
at sun.nio.cs.StreamDecoder.implRead(Unknown Source)
at sun.nio.cs.StreamDecoder.read(Unknown Source)
at java.io.InputStreamReader.read(Unknown Source)
at java.io.BufferedReader.fill(Unknown Source)
at java.io.BufferedReader.readLine(Unknown Source)
at java.io.BufferedReader.readLine(Unknown Source)
at cn.itcast_03.ServerDemo.main(ServerDemo.java:24) 作者: Fangjie 时间: 2016-6-10 10:49
把while((br.readLine())!=null){改成while((line=br.readLine())!=null)试下作者: dubei1993 时间: 2016-6-10 10:59