Commit 4ddd40cb authored by Adam Groszer's avatar Adam Groszer

adjust refcounting

parent 6b57f2a8
......@@ -643,7 +643,10 @@ pickle___setstate__(PyObject *self, PyObject *state)
for ( i=0; i<len; ++i ) {
PyObject *item = PySequence_GetItem(items, i);
if (item == NULL)
{
Py_DECREF(items);
return NULL;
}
d_key = PyTuple_GetItem(item, 0);
if (d_key == NULL)
{
......@@ -654,7 +657,6 @@ pickle___setstate__(PyObject *self, PyObject *state)
d_value = PyTuple_GetItem(item, 1);
if (d_value == NULL)
{
Py_DECREF(d_key);
Py_DECREF(item);
Py_DECREF(items);
return NULL;
......
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