diff options
author | Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> | 2024-03-04 10:04:44 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-03-04 10:04:44 (GMT) |
commit | d8a56ea439f08a2c386dae61aa503cf9daeca80f (patch) | |
tree | d512bb8d34acea366df3f6a3f1538ff73a354113 /Objects/typeobject.c | |
parent | 722b9cf9fb9504bac082f474f0756da63a3674fc (diff) | |
download | cpython-d8a56ea439f08a2c386dae61aa503cf9daeca80f.zip cpython-d8a56ea439f08a2c386dae61aa503cf9daeca80f.tar.gz cpython-d8a56ea439f08a2c386dae61aa503cf9daeca80f.tar.bz2 |
[3.12] gh-116296: Fix refleak in reduce_newobj() corner case (GH-116297) (#116299)
(cherry picked from commit 17c4849981905fb1c9bfbb2b963b6ee12e3efb2c)
Co-authored-by: Erlend E. Aasland <erlend@python.org>
Co-authored-by: Brandt Bucher <brandtbucher@microsoft.com>
Diffstat (limited to 'Objects/typeobject.c')
-rw-r--r-- | Objects/typeobject.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Objects/typeobject.c b/Objects/typeobject.c index 71d2068..7776ae2 100644 --- a/Objects/typeobject.c +++ b/Objects/typeobject.c @@ -6258,6 +6258,7 @@ reduce_newobj(PyObject *obj) } else { /* args == NULL */ + Py_DECREF(copyreg); Py_DECREF(kwargs); PyErr_BadInternalCall(); return NULL; |