diff options
author | Nikita Sobolev <mail@sobolevn.me> | 2023-02-10 03:00:58 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-10 03:00:58 (GMT) |
commit | 34c50ceb1e2d40f7faab673d2033ecaafd3c611a (patch) | |
tree | 891fd0001e5460c05281398ba09b1d3020ef531b | |
parent | 5b946d371979a772120e6ee7d37f9b735769d433 (diff) | |
download | cpython-34c50ceb1e2d40f7faab673d2033ecaafd3c611a.zip cpython-34c50ceb1e2d40f7faab673d2033ecaafd3c611a.tar.gz cpython-34c50ceb1e2d40f7faab673d2033ecaafd3c611a.tar.bz2 |
gh-101747: Fix refleak in new `OrderedDict` repr (GH-101748)
-rw-r--r-- | Objects/odictobject.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Objects/odictobject.c b/Objects/odictobject.c index ab2bbed..215a8af 100644 --- a/Objects/odictobject.c +++ b/Objects/odictobject.c @@ -1385,6 +1385,7 @@ odict_repr(PyODictObject *self) result = PyUnicode_FromFormat("%s(%R)", _PyType_Name(Py_TYPE(self)), dcopy); + Py_DECREF(dcopy); Done: Py_ReprLeave((PyObject *)self); |