summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Fuchs <fuky@asu.cas.cz>2016-03-15 11:07:26 +0100
committerJoel Rosdahl <joel@rosdahl.net>2016-07-19 15:02:34 +0200
commit96abf31ba752bb74592e1e8f2a43db61070c3f9c (patch)
tree1e23d8b9e510cc07c77ee7ded00745fabf4d5fcd
parent6de51e60215ef37768b6ff3dc732db714dd6830a (diff)
downloadminiircd-96abf31ba752bb74592e1e8f2a43db61070c3f9c.tar.gz
miniircd-96abf31ba752bb74592e1e8f2a43db61070c3f9c.zip
Avoid crashing due to "Connection reset by peer" on SSL connection error
Traceback (most recent call last): File "/opt/miniircd/bin/miniircd", line 797, in start File "/opt/miniircd/bin/miniircd", line 846, in loop File "/usr/lib/python2.7/ssl.py", line 891, in wrap_socket File "/usr/lib/python2.7/ssl.py", line 566, in __init__ File "/usr/lib/python2.7/ssl.py", line 788, in do_handshake error: [Errno 104] Connection reset by peer
-rwxr-xr-xminiircd2
1 files changed, 1 insertions, 1 deletions
diff --git a/miniircd b/miniircd
index 176c1d7..2b295e9 100755
--- a/miniircd
+++ b/miniircd
@@ -844,7 +844,7 @@ class Server(object):
server_side=True,
certfile=self.ssl_pem_file,
keyfile=self.ssl_pem_file)
- except self.ssl.SSLError as e:
+ except BaseException as e:
self.print_error(
"SSL error for connection from %s:%s: %s" % (
addr[0], addr[1], e))