mirror of
https://github.com/python/cpython.git
synced 2025-07-24 11:44:31 +00:00
PyOS_CheckStack() returns 1 when failing, not -1.
This commit is contained in:
parent
eacc4fc5e6
commit
9c0a99ec1a
1 changed files with 1 additions and 1 deletions
|
@ -402,7 +402,7 @@ PyObject_Compare(PyObject *v, PyObject *w)
|
|||
int result;
|
||||
|
||||
#if defined(USE_STACKCHECK)
|
||||
if (PyOS_CheckStack() < 0) {
|
||||
if (PyOS_CheckStack()) {
|
||||
PyErr_SetString(PyExc_MemoryError, "Stack overflow");
|
||||
return -1;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue