diff options
Diffstat (limited to 'sleekxmpp')
-rw-r--r-- | sleekxmpp/xmlstream/xmlstream.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sleekxmpp/xmlstream/xmlstream.py b/sleekxmpp/xmlstream/xmlstream.py index e491cb5a..ac0fc256 100644 --- a/sleekxmpp/xmlstream/xmlstream.py +++ b/sleekxmpp/xmlstream/xmlstream.py @@ -816,6 +816,9 @@ class XMLStream(object): def _cert_expiration(self, event): """Schedule an event for when the TLS certificate expires.""" + if not self.use_tls and not self.use_ssl: + return + def restart(): log.warn("The server certificate has expired. Restarting.") self.reconnect() |