From: Mark Shannon Date: Thu, 20 Mar 2025 15:45:43 +0000 (+0000) Subject: GH-127705: Don't call _Py_ForgetReference before _Py_Dealloc (GH-131508) X-Git-Tag: v3.14.0a7~275 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=684a759c205d3e9f6ef74d493e1d72f5ad933d68;p=thirdparty%2FPython%2Fcpython.git GH-127705: Don't call _Py_ForgetReference before _Py_Dealloc (GH-131508) --- diff --git a/Include/internal/pycore_object.h b/Include/internal/pycore_object.h index 08cbfe46b0da..30b88404bbe2 100644 --- a/Include/internal/pycore_object.h +++ b/Include/internal/pycore_object.h @@ -445,9 +445,6 @@ static inline void Py_DECREF_MORTAL(const char *filename, int lineno, PyObject * _Py_DECREF_DecRefTotal(); } if (--op->ob_refcnt == 0) { -#ifdef Py_TRACE_REFS - _Py_ForgetReference(op); -#endif _Py_Dealloc(op); } }