[3.7] bpo-37788: Fix continuous memory leak occurs when multiple subthreads which are not joined are started.#25148
[3.7] bpo-37788: Fix continuous memory leak occurs when multiple subthreads which are not joined are started.#25148hanxinke wants to merge 2 commits into
Conversation
|
Hello, and thanks for your contribution! I'm a bot set up to make sure that the project can legally accept this contribution by verifying everyone involved has signed the PSF contributor agreement (CLA). Recognized GitHub usernameWe couldn't find a bugs.python.org (b.p.o) account corresponding to the following GitHub usernames: This might be simply due to a missing "GitHub Name" entry in one's b.p.o account settings. This is necessary for legal reasons before we can look at this contribution. Please follow the steps outlined in the CPython devguide to rectify this issue. You can check yourself to see if the CLA has been received. Thanks again for the contribution, we look forward to reviewing it! |
… which are not joined are started.
|
Thanks for the PR but the 3.7 branch is in the security-fix-only phase of its life cycle and this issue does not seem to meet the criteria for a security fix. Plus the 3.8 PR for this issue has undergone review and revision and is still open. I am closing this PR for 3.7. Perhaps after the issue is resolved and merged in 3.8, we could reconsider a backport if someone can make a case that it is a valid security issue. https://devguide.python.org/devcycle/#security-branches |
Add threading.Thread._discard_tstate_locks() method to check whether the lock of other subthreads can be deleted from the _shutdown_locks list when the subthread task ends and prevent continuous leakage of tstate locks.
https://bugs.python.org/issue37788