Skip to content

Commit

Permalink
change to fix some bugs
Browse files Browse the repository at this point in the history
Fix bugs in close socket client when client close its socket.
  • Loading branch information
sampad1370 committed Aug 16, 2018
1 parent f01ce3d commit cd818df
Show file tree
Hide file tree
Showing 18 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion build/built-jar.properties
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#Fri, 10 Aug 2018 22:26:22 +0430
#Thu, 16 Aug 2018 16:40:48 +0430


D\:\\Projects\\Temp\\SocketInVBAndJava\\JavaSide=
Empty file.
Empty file.
Binary file modified build/classes/javaside/JavaSide$1.class
Binary file not shown.
Binary file modified build/classes/javaside/JavaSide$2.class
Binary file not shown.
Binary file modified build/classes/javaside/JavaSide.class
Binary file not shown.
Binary file modified build/classes/javaside/Socket/TcpClient$1.class
Binary file not shown.
Binary file modified build/classes/javaside/Socket/TcpClient.class
Binary file not shown.
Binary file modified build/classes/javaside/Socket/TcpClientEventHandler.class
Binary file not shown.
Binary file modified build/classes/javaside/Socket/TcpServer$1.class
Binary file not shown.
Binary file modified build/classes/javaside/Socket/TcpServer.class
Binary file not shown.
Binary file modified build/classes/javaside/Socket/TcpServerEventHandler.class
Binary file not shown.
Binary file added build/classes/org/shokai/evmsg/TcpClient$1.class
Binary file not shown.
Binary file not shown.
Binary file added build/classes/org/shokai/evmsg/TcpServer$1.class
Binary file not shown.
Binary file added build/classes/org/shokai/evmsg/TcpServer$2.class
Binary file not shown.
Binary file modified dist/JavaSide.jar
Binary file not shown.
11 changes: 10 additions & 1 deletion src/javaside/Socket/TcpClient.java
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,16 @@ public void run(){
Thread.sleep(readInterval);
String line = bReader.readLine();

if(handler != null) handler.onMessage(line);
if(handler != null)
{ if(line!=null)
{
handler.onMessage(line);
}
else
{
that.close();
}
}

}
catch(SocketException ex){
Expand Down

0 comments on commit cd818df

Please sign in to comment.