gh-86493: Fix possible leaks in some modules initialization#106768
gh-86493: Fix possible leaks in some modules initialization#106768serhiy-storchaka merged 2 commits intopython:mainfrom
Conversation
Fix _ssl, _stat, _testinternalcapi, _threadmodule, cmath, math, posix, time.
1bec79f to
8703a44
Compare
|
Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.11, 3.12. |
|
Sorry @serhiy-storchaka, I had trouble checking out the |
|
Sorry, @serhiy-storchaka, I could not cleanly backport this to |
|
Nice fix. I like when removing characters fix bugs :-D About the backport: Python 3.11 and 3.12 don't have PyModule_Add(), so you cannot backport these fixes, no? While it's tempting, I don't think that it's worth it. |
…ion (pythonGH-106768) Fix _ssl, _stat, _testinternalcapi, _threadmodule, cmath, math, posix, time.. (cherry picked from commit 3e65bae) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
|
GH-106855 is a backport of this pull request to the 3.12 branch. |
…ialization (pythonGH-106768) (pythonGH-106855) Fix _ssl, _stat, _testinternalcapi, _threadmodule, cmath, math, posix, time. (cherry picked from commit 3e65bae). (cherry picked from commit a423ddb) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Fix _ssl, _stat, _testinternalcapi, _threadmodule, cmath, math, posix, time.
Use new
private functionpublic function_PyModule_AddNew()PyModule_Add()instead ofPyModule_AddObject().