Commit 5b83ef71 authored by Zackery Spytz's avatar Zackery Spytz Committed by Serhiy Storchaka

bpo-35303: Fix a reference leak in _operator.c's methodcaller_repr(). (GH-10689)

parent 1d817e4c
...@@ -1583,6 +1583,7 @@ methodcaller_repr(methodcallerobject *mc) ...@@ -1583,6 +1583,7 @@ methodcaller_repr(methodcallerobject *mc)
goto done; goto done;
if (i >= numtotalargs) { if (i >= numtotalargs) {
i = -1; i = -1;
Py_DECREF(onerepr);
break; break;
} }
PyTuple_SET_ITEM(argreprs, i, onerepr); PyTuple_SET_ITEM(argreprs, i, onerepr);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment