[ python-Bugs-924242 ] socket._fileobject._getclosed() returns
wrong value
SourceForge.net
noreply at sourceforge.net
Fri Mar 26 17:03:11 EST 2004
Bugs item #924242, was opened at 2004-03-26 14:03
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=924242&group_id=5470
Category: Python Library
Group: Python 2.3
Status: Open
Resolution: None
Priority: 5
Submitted By: June Kim (gigamorph)
Assigned to: Nobody/Anonymous (nobody)
Summary: socket._fileobject._getclosed() returns wrong value
Initial Comment:
In socket.py, _getclosed() is defined as follows:
class _fileobject(object)
# ...
def _getclosed(self):
return self._sock is not None
Which causes the following interaction:
>>> import socket
>>> s = socket.socket()
>>> f = s.makefile()
>>> f.closed
True
>>> f.close()
>>> f.closed
False
Shouldn't the values of f.closed the opposite of the above?
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=924242&group_id=5470
More information about the Python-bugs-list
mailing list