This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author nvetoshkin
Recipients BreamoreBoy, exarkun, lekma, nvetoshkin, pitrou, r.david.murray
Date 2010-10-12.20:49:11
SpamBayes Score 0.000137964
Marked as misclassified No
Message-id <1286916554.53.0.857842921194.issue7523@psf.upfronthosting.co.za>
In-reply-to
Content
Thanks! I can see the problem now, but I think checking should be done like this:
>>> fcntl.fcntl(c, fcntl.F_GETFD) & fcntl.FD_CLOEXEC
0
>>> fcntl.fcntl(s, fcntl.F_GETFD) & fcntl.FD_CLOEXEC
1
and with accept4() call I've got flag set:
>>> fcntl.fcntl(c, fcntl.F_GETFD) & fcntl.FD_CLOEXEC
1
>>> fcntl.fcntl(s, fcntl.F_GETFD) & fcntl.FD_CLOEXEC
1

Don't know how to properly check if accept4 is available.

Second attempt - dropping flags from sock_type should be done on Python level in socket.py and I don't quite like idea to check if SOCK_CLOEXEC is in locals every time.
History
Date User Action Args
2010-10-12 20:49:14nvetoshkinsetrecipients: + nvetoshkin, exarkun, pitrou, r.david.murray, lekma, BreamoreBoy
2010-10-12 20:49:14nvetoshkinsetmessageid: <1286916554.53.0.857842921194.issue7523@psf.upfronthosting.co.za>
2010-10-12 20:49:12nvetoshkinlinkissue7523 messages
2010-10-12 20:49:12nvetoshkincreate