Skip to content

Commit

Permalink
gh-101965: Fix usage of Py_EnterRecursiveCall return value in _bisect…
Browse files Browse the repository at this point in the history
…module.c (GH-101966)

Closes #101965

Automerge-Triggered-By: GH:erlend-aasland
  • Loading branch information
OTheDev committed Feb 21, 2023
1 parent 02d9f15 commit 0f7a972
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Modules/_bisectmodule.c
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ internal_bisect_right(PyObject *list, PyObject *item, Py_ssize_t lo, Py_ssize_t
if (sq_item == NULL) {
return -1;
}
if (Py_EnterRecursiveCall("in _bisect.bisect_right") < 0) {
if (Py_EnterRecursiveCall("in _bisect.bisect_right")) {
return -1;
}
PyTypeObject *tp = Py_TYPE(item);
Expand Down Expand Up @@ -246,7 +246,7 @@ internal_bisect_left(PyObject *list, PyObject *item, Py_ssize_t lo, Py_ssize_t h
if (sq_item == NULL) {
return -1;
}
if (Py_EnterRecursiveCall("in _bisect.bisect_left") < 0) {
if (Py_EnterRecursiveCall("in _bisect.bisect_left")) {
return -1;
}
PyTypeObject *tp = Py_TYPE(item);
Expand Down

0 comments on commit 0f7a972

Please sign in to comment.