Removed old debug printf and improved disconnect()
This commit is contained in:
parent
afeeec67db
commit
b02bf2eaee
|
|
@ -61,6 +61,8 @@ public final class ApiConnectionImpl extends ApiConnection {
|
||||||
processor.interrupt();
|
processor.interrupt();
|
||||||
reader.interrupt();
|
reader.interrupt();
|
||||||
try {
|
try {
|
||||||
|
in.close();
|
||||||
|
out.close();
|
||||||
sock.close();
|
sock.close();
|
||||||
} catch (IOException ex) {
|
} catch (IOException ex) {
|
||||||
throw new ApiConnectionException(String.format("Error closing socket: %s", ex.getMessage()), ex);
|
throw new ApiConnectionException(String.format("Error closing socket: %s", ex.getMessage()), ex);
|
||||||
|
|
@ -322,7 +324,6 @@ public final class ApiConnectionImpl extends ApiConnection {
|
||||||
case "!halt":
|
case "!halt":
|
||||||
return unpackError();
|
return unpackError();
|
||||||
case "":
|
case "":
|
||||||
System.out.printf("sock.isClosed() = %s, sock.isInputShutdown() = %s\n", sock.isClosed(), sock.isInputShutdown());
|
|
||||||
default:
|
default:
|
||||||
throw new ApiDataException(String.format("Unexpected line '%s'", line));
|
throw new ApiDataException(String.format("Unexpected line '%s'", line));
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue