mirror of
https://github.com/python/cpython.git
synced 2025-10-02 21:25:24 +00:00
gh-101765: unicodeobject: use Py_XDECREF correctly (GH-102283)
(cherry picked from commit 8d0f09b1be
)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
This commit is contained in:
parent
eb5565918a
commit
64d3715de8
1 changed files with 1 additions and 1 deletions
|
@ -15768,7 +15768,7 @@ unicodeiter_reduce(unicodeiterobject *it, PyObject *Py_UNUSED(ignored))
|
|||
} else {
|
||||
PyObject *u = (PyObject *)_PyUnicode_New(0);
|
||||
if (u == NULL) {
|
||||
Py_DECREF(iter);
|
||||
Py_XDECREF(iter);
|
||||
return NULL;
|
||||
}
|
||||
return Py_BuildValue("N(N)", iter, u);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue