From 4fb3630896294eba227c2ab2cebd11f4b9bcf267 Mon Sep 17 00:00:00 2001 From: Florian Schmaus Date: Wed, 10 Feb 2016 12:36:38 +0100 Subject: [PATCH] Socks5Client: Throw SmackException instead of IOExecption So that we can wrap the original exception within the SmackException. It's not possible to wrap it into the IOException because of the used min Android API level. --- .../jivesoftware/smackx/bytestreams/socks5/Socks5Client.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/smack-extensions/src/main/java/org/jivesoftware/smackx/bytestreams/socks5/Socks5Client.java b/smack-extensions/src/main/java/org/jivesoftware/smackx/bytestreams/socks5/Socks5Client.java index f58a93735..373c31598 100644 --- a/smack-extensions/src/main/java/org/jivesoftware/smackx/bytestreams/socks5/Socks5Client.java +++ b/smack-extensions/src/main/java/org/jivesoftware/smackx/bytestreams/socks5/Socks5Client.java @@ -125,8 +125,8 @@ class Socks5Client { } } - // throw generic IO exception if unexpected exception was thrown - throw new IOException("Error while connection to SOCKS5 proxy"); + // throw generic Smack exception if unexpected exception was thrown + throw new SmackException("Error while connecting to SOCKS5 proxy", e); } }