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 Yi Ding, mpaolini, ned.deily, python-dev, rbcollins, ronaldoussoren, vstinner
Date 2015-09-04.15:35:10
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1441380910.89.0.0577303541705.issue24891@psf.upfronthosting.co.za>
In-reply-to
Content
> @haypo, yeah, definitely better than mine! All good for me.

Ok. I added your name to Misc/ACKS. I had to do some tricks to apply the patch to Python 3.4 (code was in Python/pythonrun.c) and then to merge to Python 3.5 (code moved to Python/pylifecycle.c). But I checked the fix in each version using gdb:

* put a breakpoint on create_stdio,
* type "print close(0)" after the first is_valid_fd() check,
* see that the open() exception is correctly handled (type "next", "next", ... and check that we go to the error: label and then enter the if() block)

Thanks for your patch Marco.

I prefer to be extra safe by checking the raised exception to minimize the risk of regression.
History
Date User Action Args
2015-09-04 15:35:10vstinnersetrecipients: + vstinner, ronaldoussoren, rbcollins, ned.deily, python-dev, mpaolini, Yi Ding
2015-09-04 15:35:10vstinnersetmessageid: <1441380910.89.0.0577303541705.issue24891@psf.upfronthosting.co.za>
2015-09-04 15:35:10vstinnerlinkissue24891 messages
2015-09-04 15:35:10vstinnercreate