]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-92036: Fix gc_fini_untrack() (#92037)
authorVictor Stinner <vstinner@python.org>
Wed, 4 May 2022 09:59:01 +0000 (11:59 +0200)
committerGitHub <noreply@github.com>
Wed, 4 May 2022 09:59:01 +0000 (11:59 +0200)
commit14243369b5f80613628a565c224bba7fb3fcacd8
tree119324ec05e3abf2f6872c5a12d0514411d24a9d
parentd20bb33f782f5677256d7e1f2462b78113692969
gh-92036: Fix gc_fini_untrack() (#92037)

Fix a crash in subinterpreters related to the garbage collector. When
a subinterpreter is deleted, untrack all objects tracked by its GC.
To prevent a crash in deallocator functions expecting objects to be
tracked by the GC, leak a strong reference to these objects on
purpose, so they are never deleted and their deallocator functions
are not called.
Misc/NEWS.d/next/Core and Builtins/2022-04-28-23-37-30.gh-issue-92036.GZJAC9.rst [new file with mode: 0644]
Modules/gcmodule.c