@@ -138,8 +138,8 @@ public void receiveThread() {
138
138
} else if (exceptionCause instanceof EOFException ) {
139
139
handleDisconnect (DisconnectCause .LOST_CONNECTION , e );
140
140
} else if (exceptionCause instanceof IOException
141
- && exceptionCause .getCause () != null && exceptionCause
142
- .getCause () instanceof InterruptedException ) {
141
+ && exceptionCause .getCause () != null
142
+ && exceptionCause .getCause () instanceof InterruptedException ) {
143
143
handleDisconnect (DisconnectCause .LOST_CONNECTION , e );
144
144
} else {
145
145
handleDisconnect (DisconnectCause .PROTOCOL_ERROR , e );
@@ -201,8 +201,6 @@ protected final void handleDisconnect(DisconnectCause cause) {
201
201
protected final void handleDisconnect (DisconnectCause cause , Throwable exception ) {
202
202
if (exception != null ) {
203
203
logger .warn ("{} disconnected (Cause: {}, Exception: {})" , this , cause , exception );
204
- if (logger .isDebugEnabled ())
205
- exception .printStackTrace ();
206
204
} else {
207
205
logger .info ("{} disconnected (Cause: {})" , this , cause );
208
206
}
@@ -263,7 +261,7 @@ protected synchronized void close() {
263
261
this .out .close ();
264
262
} catch (Exception e ) {
265
263
if (e .getCause () instanceof SocketException )
266
- logger .debug ("Failed to close OUT" , e );
264
+ logger .debug ("Can't close OUT, Socket already closed: {} " , e . toString () );
267
265
else
268
266
logger .warn ("Failed to close OUT" , e );
269
267
}
0 commit comments