Skip to content

Commit fe7e7f5

Browse files
committed
_pickle: fix refleak
1 parent e90156e commit fe7e7f5

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

Modules/_pickle.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -611,6 +611,7 @@ Pdata_poplist2(PickleState *state, Pdata *self, Py_ssize_t start)
611611
for (Py_ssize_t i = start, j = 0; j < len; i+=2, j++) {
612612
PyObject *subtuple = PyTuple_New(2);
613613
if (subtuple == NULL) {
614+
Py_DECREF(list);
614615
return NULL;
615616
}
616617

0 commit comments

Comments
 (0)