summaryrefslogtreecommitdiffstats
path: root/Lib/ssl.py
diff options
context:
space:
mode:
authorAntoine Pitrou <solipsis@pitrou.net>2010-04-23 23:35:01 (GMT)
committerAntoine Pitrou <solipsis@pitrou.net>2010-04-23 23:35:01 (GMT)
commitd4030dacc6b515c3050fdcc59b919d8fcc9ac2c7 (patch)
treeec5a75803f88bf59bad68ef1d594db6b9ef9ba02 /Lib/ssl.py
parent3df58d11be781c6842d64bb5e8d591659e1f5c0b (diff)
downloadcpython-d4030dacc6b515c3050fdcc59b919d8fcc9ac2c7.zip
cpython-d4030dacc6b515c3050fdcc59b919d8fcc9ac2c7.tar.gz
cpython-d4030dacc6b515c3050fdcc59b919d8fcc9ac2c7.tar.bz2
Merged revisions 80428 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk ........ r80428 | antoine.pitrou | 2010-04-24 01:25:45 +0200 (sam., 24 avril 2010) | 4 lines Issue #5238: Calling makefile() on an SSL object would prevent the underlying socket from being closed until all objects get truely destroyed. ........
Diffstat (limited to 'Lib/ssl.py')
-rw-r--r--Lib/ssl.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/Lib/ssl.py b/Lib/ssl.py
index 0ebef58..3ee3d6a 100644
--- a/Lib/ssl.py
+++ b/Lib/ssl.py
@@ -320,7 +320,9 @@ class SSLSocket(socket):
from the socket module."""
self._makefile_refs += 1
- return _fileobject(self, mode, bufsize)
+ # close=True so as to decrement the reference count when done with
+ # the file-like object.
+ return _fileobject(self, mode, bufsize, close=True)