summaryrefslogtreecommitdiff
path: root/sleekxmpp/xmlstream/xmlstream.py
diff options
context:
space:
mode:
Diffstat (limited to 'sleekxmpp/xmlstream/xmlstream.py')
-rw-r--r--sleekxmpp/xmlstream/xmlstream.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/sleekxmpp/xmlstream/xmlstream.py b/sleekxmpp/xmlstream/xmlstream.py
index 3b0271dc..b14ed5eb 100644
--- a/sleekxmpp/xmlstream/xmlstream.py
+++ b/sleekxmpp/xmlstream/xmlstream.py
@@ -485,7 +485,10 @@ class XMLStream(object):
try:
if not self.use_proxy:
- log.debug("Connecting to %s:%s", *self.address)
+ domain = self.address[0]
+ if ':' in domain:
+ domain = '[%s]' % domain
+ log.debug("Connecting to %s:%s", domain, self.address[1])
self.socket.connect(self.address)
if self.use_ssl and self.ssl_support: