]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
bpo-40550: Fix time-of-check/time-of-action issue in subprocess.Popen.send_signal...
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Sat, 21 Nov 2020 09:46:21 +0000 (01:46 -0800)
committerGitHub <noreply@github.com>
Sat, 21 Nov 2020 09:46:21 +0000 (01:46 -0800)
commit713b4bbd97392acc492a4fefb2d07ae61fb7b75d
tree30d3c2270e96cc908c5c9cf1a9d3da01871bc87e
parentc1bbca5b004b3f74d240ef8a76ff445cc1a27efb
bpo-40550: Fix time-of-check/time-of-action issue in subprocess.Popen.send_signal. (GH-20010)

send_signal() now swallows the exception if the process it thought was still alive winds up not to exist anymore (always a plausible race condition despite the checks).

Co-authored-by: Gregory P. Smith <greg@krypto.org>
(cherry picked from commit 01a202ab6b0ded546e47073db6498262086c52e9)

Co-authored-by: Filipe LaĆ­ns <lains@archlinux.org>
Lib/subprocess.py
Lib/test/test_subprocess.py
Misc/NEWS.d/next/Library/2020-05-08-21-30-54.bpo-40550.i7GWkb.rst [new file with mode: 0644]