[issue7995] On Mac / BSD sockets returned by accept inherit the parent's FD flags

Kristján Valur Jónsson report at bugs.python.org
Wed Mar 30 15:58:55 CEST 2011


Kristján Valur Jónsson <kristjan at ccpgames.com> added the comment:

Please see issue 11721 where I was commenting on the same.

I don't think the documentation makes it clear that socket.gettimeout() can be incorrect (i.e. return None when the socket is non-blocking).

I also don't think there is a portable way to detect the NBIO attribute of a socket, so we still have a case of socket.gettimeout() not accurately reflecting the blocking state of the socket.  If people don't think it is a bug, then this fact should be documented.

I personally think that this logic should go into socketmodule.c where the rest of the timeout logic sits, rather than be exctracted like this out into the python world.

Finally, IMHO this is a bug that should be backported as far back as possible.

Cheers!

----------
nosy: +krisvale

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue7995>
_______________________________________


More information about the Python-bugs-list mailing list