Fix actually compatibility with non-ssl envirronments

This commit is contained in:
Valentin Lorentz 2010-12-12 14:33:36 +01:00
parent a58e270516
commit 49dfa69b91

View File

@ -39,8 +39,10 @@ import select
import socket
try:
import ssl
SSLError = ssl.SSLError
except:
pass
class SSLError(Exception):
pass
import supybot.log as log
import supybot.conf as conf
@ -144,7 +146,7 @@ class SocketDriver(drivers.IrcDriver, drivers.ServersMixin):
self.irc.feedMsg(msg)
except socket.timeout:
pass
except ssl.SSLError, e:
except SSLError, e:
if e.args[0] == 'The read operation timed out':
pass
else: