Commit c89d28fd authored by Victor Stinner's avatar Victor Stinner

Issue #15609: Fix refleak introduced by my last optimization

parent 450dbcf4
...@@ -13449,8 +13449,11 @@ mainformatlong(_PyUnicodeWriter *writer, PyObject *v, ...@@ -13449,8 +13449,11 @@ mainformatlong(_PyUnicodeWriter *writer, PyObject *v,
break; break;
} }
if (_PyLong_FormatWriter(writer, v, base, alternate) == -1) if (_PyLong_FormatWriter(writer, v, base, alternate) == -1) {
Py_DECREF(iobj);
return -1; return -1;
}
Py_DECREF(iobj);
return 1; return 1;
} }
......
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