diff --git a/smack-extensions/src/main/java/org/jivesoftware/smackx/bytestreams/socks5/Socks5Proxy.java b/smack-extensions/src/main/java/org/jivesoftware/smackx/bytestreams/socks5/Socks5Proxy.java index 928990970..61a26c9ab 100644 --- a/smack-extensions/src/main/java/org/jivesoftware/smackx/bytestreams/socks5/Socks5Proxy.java +++ b/smack-extensions/src/main/java/org/jivesoftware/smackx/bytestreams/socks5/Socks5Proxy.java @@ -230,12 +230,7 @@ public final class Socks5Proxy { return; } - try { - this.serverSocket.close(); - } - catch (IOException e) { - // do nothing - } + CloseableUtil.maybeClose(this.serverSocket, LOGGER); if (this.serverThread != null && this.serverThread.isAlive()) { try {