diff options
author | Jakub KulĂk <Kulikjak@gmail.com> | 2023-12-17 21:34:57 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-12-17 21:34:57 (GMT) |
commit | 2b93f5224216d10f8119373e72b5c2b3984e0af6 (patch) | |
tree | 2fe266d813dedeef8a19822a0db19713a8f460e5 /Misc | |
parent | 32d87a88994c131a9f3857d01ae7c07918577a55 (diff) | |
download | cpython-2b93f5224216d10f8119373e72b5c2b3984e0af6.zip cpython-2b93f5224216d10f8119373e72b5c2b3984e0af6.tar.gz cpython-2b93f5224216d10f8119373e72b5c2b3984e0af6.tar.bz2 |
gh-113117: Support posix_spawn in subprocess.Popen with close_fds=True (#113118)
Add support for `os.POSIX_SPAWN_CLOSEFROM` and
`posix_spawn_file_actions_addclosefrom_np` and have the `subprocess` module use
them when available. This means `posix_spawn` can now be used in the default
`close_fds=True` situation on many platforms.
Co-authored-by: Gregory P. Smith [Google LLC] <greg@krypto.org>
Diffstat (limited to 'Misc')
-rw-r--r-- | Misc/NEWS.d/next/Library/2023-12-16-10-58-34.gh-issue-113117.0zF7bH.rst | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Misc/NEWS.d/next/Library/2023-12-16-10-58-34.gh-issue-113117.0zF7bH.rst b/Misc/NEWS.d/next/Library/2023-12-16-10-58-34.gh-issue-113117.0zF7bH.rst new file mode 100644 index 0000000..718226a --- /dev/null +++ b/Misc/NEWS.d/next/Library/2023-12-16-10-58-34.gh-issue-113117.0zF7bH.rst @@ -0,0 +1,4 @@ +The :mod:`subprocess` module can now use the :func:`os.posix_spawn` function +with ``close_fds=True`` on platforms where +``posix_spawn_file_actions_addclosefrom_np`` is available. +Patch by Jakub Kulik. |