aboutsummaryrefslogtreecommitdiffstats
path: root/src/eu/siacs/conversations/xmpp/XmppConnection.java
diff options
context:
space:
mode:
authorDaniel Gultsch <daniel.gultsch@rwth-aachen.de>2014-03-28 19:00:01 +0100
committerDaniel Gultsch <daniel.gultsch@rwth-aachen.de>2014-03-28 19:00:01 +0100
commit38efb84690f5ed46ad34b0a5cb27e63da73394bd (patch)
tree75cf499bf309bf557e1db5926b0238da0e0170e2 /src/eu/siacs/conversations/xmpp/XmppConnection.java
parent268eae78136a2ef2c2fe53aee4f003ffa6bf9a89 (diff)
treat dns timeouts as temporary. also increased timeout
Diffstat (limited to 'src/eu/siacs/conversations/xmpp/XmppConnection.java')
-rw-r--r--src/eu/siacs/conversations/xmpp/XmppConnection.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/eu/siacs/conversations/xmpp/XmppConnection.java b/src/eu/siacs/conversations/xmpp/XmppConnection.java
index e265b997..a32256ff 100644
--- a/src/eu/siacs/conversations/xmpp/XmppConnection.java
+++ b/src/eu/siacs/conversations/xmpp/XmppConnection.java
@@ -123,6 +123,11 @@ public class XmppConnection implements Runnable {
packetCallbacks.clear();
this.changeStatus(Account.STATUS_CONNECTING);
Bundle namePort = DNSHelper.getSRVRecord(account.getServer());
+ if ("timeout".equals(namePort.getString("error"))) {
+ Log.d(LOGTAG,account.getJid()+": dns timeout");
+ this.changeStatus(Account.STATUS_OFFLINE);
+ return;
+ }
String srvRecordServer = namePort.getString("name");
int srvRecordPort = namePort.getInt("port");
if (srvRecordServer != null) {