]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-129668: Fix thread-safety of MemoryError freelist in free threaded build (gh-129704)
authorSam Gross <colesbury@gmail.com>
Thu, 6 Feb 2025 17:38:12 +0000 (12:38 -0500)
committerGitHub <noreply@github.com>
Thu, 6 Feb 2025 17:38:12 +0000 (12:38 -0500)
commit51b4edb1a4092f60d84f7d14eb41c12085e39c31
tree48863ba4beaa03b14b11ce5a151855e0c8590023
parent4d56c40440c9fd4499d61d24977336d8cd8d8d83
gh-129668: Fix thread-safety of MemoryError freelist in free threaded build (gh-129704)

The MemoryError freelist was not thread-safe in the free threaded build.
Use a mutex to protect accesses to the freelist. Unlike other freelists,
the MemoryError freelist is not performance sensitive.
Include/internal/pycore_exceptions.h
Misc/NEWS.d/next/Core_and_Builtins/2025-02-04-21-26-05.gh-issue-129668.zDanyM.rst [new file with mode: 0644]
Objects/exceptions.c