mirror of
https://github.com/python/cpython.git
synced 2026-04-14 07:41:00 +00:00
[3.13] gh-144706: Warn against using synchronization primitives within signal handlers (GH-144736) (GH-144768)
gh-144706: Warn against using synchronization primitives within signal handlers (GH-144736)
(cherry picked from commit 945bf8ce1b)
Co-authored-by: Robsdedude <dev@rouvenbauer.de>
This commit is contained in:
parent
2f354107f3
commit
99a4e55f79
1 changed files with 5 additions and 0 deletions
|
|
@ -68,6 +68,11 @@ the synchronization primitives from the :mod:`threading` module instead.
|
|||
|
||||
Besides, only the main thread of the main interpreter is allowed to set a new signal handler.
|
||||
|
||||
.. warning::
|
||||
|
||||
Synchronization primitives such as :class:`threading.Lock` should not be used
|
||||
within signal handlers. Doing so can lead to unexpected deadlocks.
|
||||
|
||||
|
||||
Module contents
|
||||
---------------
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue