homepage

This issue tracker has been migrated to GitHub , and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vstinner
Recipients Evgeny.Tarasov, alexey-smirnov, chn, neologix, pitrou, r.david.murray, rosslagerwall, socketpair, vstinner
Date 2011年07月25日.09:51:07
SpamBayes Score 1.3517364e-05
Marked as misclassified No
Message-id <1311587467.81.0.986451643197.issue12607@psf.upfronthosting.co.za>
In-reply-to
Content
save_fds should be moved outside the try block:
+ try:
+ # save a copy of the standard file descriptors
+ saved_fds = [os.dup(fd) for fd in range(3)]
+ ...
+ finally:
+ for std, saved in enumerate(saved_fds):
+ os.dup2(saved, std)
+ os.close(saved)
"temp_fds = [fd for fd, fname in temps]" should also be moved outside its try block.
Why not using .communicate() to write into stdin and read stdout/stderr?
History
Date User Action Args
2011年07月25日 09:51:07vstinnersetrecipients: + vstinner, pitrou, r.david.murray, neologix, rosslagerwall, socketpair, alexey-smirnov, Evgeny.Tarasov, chn
2011年07月25日 09:51:07vstinnersetmessageid: <1311587467.81.0.986451643197.issue12607@psf.upfronthosting.co.za>
2011年07月25日 09:51:07vstinnerlinkissue12607 messages
2011年07月25日 09:51:07vstinnercreate

AltStyle によって変換されたページ (->オリジナル) /