Feb. 26, 2021
9:17 p.m.
Eryk Sun <eryksun@gmail.com> added the comment: This problem can be addressed most easily in _get_handles() by combining the case of an invalid standard handle with that of a NULL standard handle, for which a file handle is validated via GetFileType(). However, that leaves a small window for the handle to become invalid before duplicating it. Instead, _get_handles() could deal with a failed _make_inheritable() call by substituting a pipe handle. ---------- versions: +Python 3.10, Python 3.8, Python 3.9 -Python 2.7, Python 3.6, Python 3.7 _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue29829> _______________________________________