Message136328
Using spawn_python() to check that os.O_CLOEXEC flag is correctly set seems overkill. Why not just testing fcntl.fcntl(f.fileno(), fcntl.F_GETFL) & FD_CLOEXEC)? I don't think that there are OSes with O_CLOEXEC but without fcntl(F_GETFL).
> Note that I'm not sure that adding this flag to built-in open()
> is necessarily a good idea
I agree.
open() documentation may explain the os.fdopen(os.open()) "trick" to use low-level options like O_SYNC or O_CLOEXEC. |
|
Date |
User |
Action |
Args |
2011-05-19 19:15:32 | vstinner | set | recipients:
+ vstinner, amaury.forgeotdarc, neologix, socketpair, alexey-smirnov |
2011-05-19 19:15:32 | vstinner | set | messageid: <1305832532.67.0.252255366596.issue12105@psf.upfronthosting.co.za> |
2011-05-19 19:15:32 | vstinner | link | issue12105 messages |
2011-05-19 19:15:32 | vstinner | create | |
|