[Python-Dev] PEP 433: Choose the default value of the new cloexec parameter

Victor Stinner victor.stinner at gmail.com
Sat Jan 26 12:28:59 CET 2013


> So, if we agree that "cloexec-by-default" is a desirable goal, despite
> the inconsistency with POSIX (just as changing integer division was
> seen as desirable, despite the inconsistency with C) ...

I don't plan to enable cloexec by default in a near future, nor in python
4. Someone else may change that later. Having a global flag should be
enough.

Enabling cloexec by default is interesting if *all* libraries respect the
global flag (even C libraries), so subprocess can be used with
close_fds=False. Closing all file descriptors is slow, especially on
FreeBSD (it's now faster on linux, python lists /proc/pid/fd/).

Victor
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20130126/890d8f4d/attachment.html>


More information about the Python-Dev mailing list