Message196393
Yes, the problem is that the pipes FDs are closed twice if fork() succeeds, but exec() fails.
They're closed in _execute_child():
1286 if p2cread is not None and p2cwrite is not None:
1287 os.close(p2cread)
1288 if c2pwrite is not None and c2pread is not None:
1289 os.close(c2pwrite)
1290 if errwrite is not None and errread is not None:
1291 os.close(errwrite)
And then again in Popen.__init__:
716 if stdin == PIPE:
717 to_close.extend((p2cread, p2cwrite))
718 if stdout == PIPE:
719 to_close.extend((c2pread, c2pwrite))
720 if stderr == PIPE:
721 to_close.extend((errread, errwrite)) |
|
Date |
User |
Action |
Args |
2013-08-28 17:50:16 | neologix | set | recipients:
+ neologix, gregory.p.smith, pitrou, janwijbrand, Jeong-Min.Lee |
2013-08-28 17:50:16 | neologix | set | messageid: <1377712216.33.0.344375875746.issue18851@psf.upfronthosting.co.za> |
2013-08-28 17:50:16 | neologix | link | issue18851 messages |
2013-08-28 17:50:16 | neologix | create | |
|