mirror of
https://github.com/python/cpython.git
synced 2025-07-30 14:44:10 +00:00
Issue #18408: Fix Py_ReprEnter(), handle PyList_Append() failure
This commit is contained in:
parent
095d99ffff
commit
e901d1fbdf
1 changed files with 2 additions and 1 deletions
|
@ -1910,7 +1910,8 @@ Py_ReprEnter(PyObject *obj)
|
||||||
if (PyList_GET_ITEM(list, i) == obj)
|
if (PyList_GET_ITEM(list, i) == obj)
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
PyList_Append(list, obj);
|
if (PyList_Append(list, obj) < 0)
|
||||||
|
return -1;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue