mirror of
https://github.com/python/cpython.git
synced 2025-10-10 00:43:41 +00:00
gh-109593: Fix reentrancy issue in multiprocessing resource_tracker (#109629)
--------- Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
This commit is contained in:
parent
2897142d2e
commit
0eb98837b6
7 changed files with 95 additions and 2 deletions
|
@ -245,6 +245,13 @@ class _RLock:
|
|||
def _is_owned(self):
|
||||
return self._owner == get_ident()
|
||||
|
||||
# Internal method used for reentrancy checks
|
||||
|
||||
def _recursion_count(self):
|
||||
if self._owner != get_ident():
|
||||
return 0
|
||||
return self._count
|
||||
|
||||
_PyRLock = _RLock
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue