Message266592
I don’t see any violation or anything needing fixing in the documentation or code. Can you elaborate?
The fcntl() documentation says “The values used for ‘cmd’ [F_DUPFD, etc] are operating system dependent, and are available as constants in the ‘fcntl’ module, using the same names as used in the relevant C header files.” The newest version of Posix specifies both the F_DUPFD and F_DUPFD_CLOEXEC. It would be misleading for Python to use one when the user specified the other.
If you want a best-effort version of F_DUPFD_CLOEXEC for a single-threaded program, why not use os.dup()? I presume this uses F_DUPFD_CLOEXEC where appropriate, and uses some non-atomic fallback if necessary. |
|
Date |
User |
Action |
Args |
2016-05-29 08:10:27 | martin.panter | set | recipients:
+ martin.panter, vstinner, docs@python, socketpair |
2016-05-29 08:10:27 | martin.panter | set | messageid: <1464509427.68.0.396436938394.issue27150@psf.upfronthosting.co.za> |
2016-05-29 08:10:27 | martin.panter | link | issue27150 messages |
2016-05-29 08:10:27 | martin.panter | create | |
|