Commit 4f8666ed authored by Denis Bilenko's avatar Denis Bilenko

ssl.py bug fix: in certain cases, exc_clear() was followed by 'raise', causing...

ssl.py bug fix: in certain cases, exc_clear() was followed by 'raise', causing TypeError. Issue #124. Thanks to Johan Mjones.
parent 8a87c611
......@@ -263,9 +263,9 @@ class SSLSocket(socket):
except SSLError:
x = sys.exc_info()[1]
if x.args[0] == SSL_ERROR_WANT_READ:
sys.exc_clear()
if self.timeout == 0.0:
raise
sys.exc_clear()
try:
self._wait(self._read_event)
except socket_error:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment