summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--slixmpp/xmlstream/xmlstream.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/slixmpp/xmlstream/xmlstream.py b/slixmpp/xmlstream/xmlstream.py
index f11a4a16..bd6c4e6f 100644
--- a/slixmpp/xmlstream/xmlstream.py
+++ b/slixmpp/xmlstream/xmlstream.py
@@ -302,7 +302,8 @@ class XMLStream(asyncio.BaseProtocol):
yield from self.loop.create_connection(lambda: self,
self.address[0],
self.address[1],
- ssl=self.use_ssl)
+ ssl=self.use_ssl,
+ server_hostname=self.default_domain if self.use_ssl else None)
except Socket.gaierror as e:
self.event('connection_failed',
'No DNS record available for %s' % self.default_domain)