mirror of
https://github.com/python/cpython.git
synced 2025-10-29 01:22:59 +00:00
Issue #6559: fix the subprocess.Popen pass_fds implementation. Add a unittest.
Issue #7213: Change the close_fds default on Windows to better match the new default on POSIX. True when possible (False if stdin/stdout/stderr are supplied). Update the documentation to reflect all of the above.
This commit is contained in:
parent
39f34aa1f3
commit
8edd99d085
5 changed files with 79 additions and 27 deletions
|
|
@ -107,7 +107,7 @@ static void child_exec(char *const exec_array[],
|
|||
errno = 0; /* We don't want to report an OSError. */
|
||||
goto error;
|
||||
}
|
||||
if (keep_fd <= start_fd)
|
||||
if (keep_fd < start_fd)
|
||||
continue;
|
||||
for (fd_num = start_fd; fd_num < keep_fd; ++fd_num) {
|
||||
close(fd_num);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue