summaryrefslogtreecommitdiffstats
path: root/Python/sysmodule.c
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2023-10-05 19:24:26 (GMT)
committerGitHub <noreply@github.com>2023-10-05 19:24:26 (GMT)
commit2ab41c8fbc6beafebe44f232227cb593cbe7a0bd (patch)
tree95ce7d1d535bb02b6d79e40b0881dbcae2b16866 /Python/sysmodule.c
parent5b66fe8304feaf39754e83c21cdfea110e688434 (diff)
downloadcpython-2ab41c8fbc6beafebe44f232227cb593cbe7a0bd.zip
cpython-2ab41c8fbc6beafebe44f232227cb593cbe7a0bd.tar.gz
cpython-2ab41c8fbc6beafebe44f232227cb593cbe7a0bd.tar.bz2
[3.12] gh-110167: Fix test_socket deadlock in doCleanups() (GH-110416) (#110423)
gh-110167: Fix test_socket deadlock in doCleanups() (GH-110416) Fix a deadlock in test_socket when server fails with a timeout but the client is still running in its thread. Don't hold a lock to call cleanup functions in doCleanups(). One of the cleanup function waits until the client completes, whereas the client could deadlock if it called addCleanup() in such situation. doCleanups() is called when the server completed, but the client can still be running in its thread especially if the server failed with a timeout. Don't put a lock on doCleanups() to prevent deadlock between addCleanup() called in the client and doCleanups() waiting for self.done.wait of ThreadableTest._setUp(). (cherry picked from commit 318f5df27109ff8d2519edefa771920a0ec62b92) Co-authored-by: Victor Stinner <vstinner@python.org>
Diffstat (limited to 'Python/sysmodule.c')
0 files changed, 0 insertions, 0 deletions