Browse Source

Avoid closing fromServerReader in case of null

remotes/origin/feature/client/exchange-messages-between-client-server
Alena Bandarovich 11 months ago
parent
commit
64626610ca
  1. 2
      src/main/java/ChatClient.java

2
src/main/java/ChatClient.java

@ -69,11 +69,13 @@ public class ChatClient extends JFrame implements KeyListener {
}
}
if (null != fromServerReader) {
try {
fromServerReader.close();
} catch (IOException e) {
e.printStackTrace();
}
}
toServerWriter.close();

Loading…
Cancel
Save