Merged revisions 80456 via svnmerge from

svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r80456 | antoine.pitrou | 2010-04-25 00:04:40 +0200 (dim., 25 avril 2010) | 5 lines

  Issue #8524: When creating an SSL socket, the timeout value of the
  original socket wasn't retained (instead, a socket with a positive timeout
  would be turned into a non-blocking SSL socket).
........
This commit is contained in:
Antoine Pitrou 2010-04-24 22:07:51 +00:00
parent ec146185c4
commit c2203f92ff
3 changed files with 23 additions and 11 deletions

View file

@ -101,6 +101,7 @@ class SSLSocket(socket):
type=sock.type,
proto=sock.proto,
fileno=_dup(sock.fileno()))
self.settimeout(sock.gettimeout())
sock.close()
elif fileno is not None:
socket.__init__(self, fileno=fileno)