4 messages in org.python.python-bugs-list[ python-Bugs-924242 ] socket._fileob...
FromSent OnAttachments
SourceForge.netMar 26, 2004 5:02 pm 
SourceForge.netMar 26, 2004 5:04 pm 
SourceForge.netMar 27, 2004 9:04 pm 
SourceForge.netMar 27, 2004 9:32 pm 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:[ python-Bugs-924242 ] socket._fileobject._getclosed() returns wrong valueActions...
From:SourceForge.net (nore@sourceforge.net)
Date:Mar 26, 2004 5:02:54 pm
List:org.python.python-bugs-list

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?

----------------------------------------------------------------------