summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorent Le Coz <louiz@louiz.org>2014-11-05 01:11:44 +0100
committerFlorent Le Coz <louiz@louiz.org>2014-11-05 01:11:44 +0100
commit68e35e631a184fd3bdbfaf1ecc1c7e1e8c079414 (patch)
treeba4ad603ddb13f9ad48564016a618beff1320283
parentad8c76602b606ab3ac1ccbf3160692413c01a78c (diff)
downloadslixmpp-68e35e631a184fd3bdbfaf1ecc1c7e1e8c079414.tar.gz
slixmpp-68e35e631a184fd3bdbfaf1ecc1c7e1e8c079414.tar.bz2
slixmpp-68e35e631a184fd3bdbfaf1ecc1c7e1e8c079414.tar.xz
slixmpp-68e35e631a184fd3bdbfaf1ecc1c7e1e8c079414.zip
Also work without SRV records
-rw-r--r--slixmpp/xmlstream/resolver.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/slixmpp/xmlstream/resolver.py b/slixmpp/xmlstream/resolver.py
index b4144cc3..ab1424aa 100644
--- a/slixmpp/xmlstream/resolver.py
+++ b/slixmpp/xmlstream/resolver.py
@@ -128,6 +128,9 @@ def resolve(host, port=None, service=None, proto='tcp',
hosts = yield from get_SRV(host, port, service, proto,
resolver=resolver,
use_aiodns=use_aiodns)
+ if not hosts:
+ hosts = [(host, port)]
+
results = []
for host, port in hosts:
if host == 'localhost':