diff --git a/src/eu/siacs/conversations/xmpp/XmppConnection.java b/src/eu/siacs/conversations/xmpp/XmppConnection.java index ffa438bd..2a72f4c2 100644 --- a/src/eu/siacs/conversations/xmpp/XmppConnection.java +++ b/src/eu/siacs/conversations/xmpp/XmppConnection.java @@ -185,8 +185,14 @@ public class XmppConnection implements Runnable { socketError = false; } catch (UnknownHostException e) { srvIndex++; + if (!namePort.containsKey("name" + srvIndex)) { + throw e; + } } catch (IOException e) { srvIndex++; + if (!namePort.containsKey("name" + srvIndex)) { + throw e; + } } } }