]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
[3.13] gh-121390: tracemalloc: Fix tracebacks memory leak (GH-121391) (#121392)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Sun, 21 Jul 2024 13:12:13 +0000 (15:12 +0200)
committerGitHub <noreply@github.com>
Sun, 21 Jul 2024 13:12:13 +0000 (13:12 +0000)
commit4b76404a511c287a73e32eef927f7cc4377d3055
tree1dbe7031650911041b605fd625987705017fdf26
parent66435241d89b1f667e225170d50bcb7b42f76abf
[3.13] gh-121390: tracemalloc: Fix tracebacks memory leak (GH-121391) (#121392)

gh-121390: tracemalloc: Fix tracebacks memory leak (GH-121391)

The tracemalloc_tracebacks hash table has traceback keys and NULL
values, but its destructors do not reflect this -- key_destroy_func is
NULL while value_destroy_func is raw_free. Swap these to free the
traceback keys instead.
(cherry picked from commit db39bc42f90c151b298f97b780e62703adbf1221)

Co-authored-by: Josh Brobst <jbrobst@proton.me>
Python/tracemalloc.c