Commit 2c6799ab authored by Antoine Pitrou's avatar Antoine Pitrou

Revert r79384 (the fix failed).

parent fb224e30
......@@ -315,21 +315,12 @@ if ssl is not None:
raise
def close(self):
ssl_want_read_or_write = False
try:
if isinstance(self.socket, ssl.SSLSocket):
if self.socket._sslobj is not None:
try:
self.socket.unwrap()
except ssl.SSLError, err:
if err.args[0] in (ssl.SSL_ERROR_WANT_READ,
ssl.SSL_ERROR_WANT_WRITE):
ssl_want_read_or_write = True
else:
raise
self.socket.unwrap()
finally:
if not ssl_want_read_or_write:
super(SSLConnection, self).close()
super(SSLConnection, self).close()
class DummyTLS_DTPHandler(SSLConnection, DummyDTPHandler):
......
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