From: Eric Snow Date: Wed, 3 Apr 2024 01:10:26 +0000 (-0600) Subject: gh-76785: Fix a Refleak in _interpreters.new_config() (gh-117491) X-Git-Tag: v3.13.0a6~67 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=65524ab38875bb0b89fb499531bb772a4fb45b01;p=thirdparty%2FPython%2Fcpython.git gh-76785: Fix a Refleak in _interpreters.new_config() (gh-117491) This is a follow-up to gh-117170 and gh-117485. --- diff --git a/Python/interpconfig.c b/Python/interpconfig.c index 419f40ae62a8..54e5dca284c2 100644 --- a/Python/interpconfig.c +++ b/Python/interpconfig.c @@ -210,6 +210,8 @@ interp_config_from_dict(PyObject *origdict, PyInterpreterConfig *config, "config dict has %d extra items (%R)", unused, dict); goto error; } + + Py_DECREF(dict); return 0; error: