Author vstinner
Recipients vstinner
Date 2016-04-15.13:20:59
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1460726460.32.0.344896145272.issue26770@psf.upfronthosting.co.za>
In-reply-to
Content
Attached patch is avoids a syscall in os.set_inheritable() if the FD_CLOEXEC flag is already set/cleared.

The change only impacts platforms using fcntl() in _Py_set_inheritable(). Windows has a different implementation, and Linux uses ioctl() for example.

The same "optimization" is used in socket.socket.setblocking(): see the issue #19827.
History
Date User Action Args
2016-04-15 13:21:00vstinnersetrecipients: + vstinner
2016-04-15 13:21:00vstinnersetmessageid: <1460726460.32.0.344896145272.issue26770@psf.upfronthosting.co.za>
2016-04-15 13:21:00vstinnerlinkissue26770 messages
2016-04-15 13:21:00vstinnercreate