mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
gh-96538: Fix refleak in _bisectmodule.c (gh-96619)
This commit is contained in:
parent
147eb723b2
commit
56d9cf7fc8
2 changed files with 30 additions and 0 deletions
|
@ -120,6 +120,7 @@ internal_bisect_right(PyObject *list, PyObject *item, Py_ssize_t lo, Py_ssize_t
|
|||
}
|
||||
else {
|
||||
res = PyObject_IsTrue(res_obj);
|
||||
Py_DECREF(res_obj);
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
@ -299,6 +300,7 @@ internal_bisect_left(PyObject *list, PyObject *item, Py_ssize_t lo, Py_ssize_t h
|
|||
}
|
||||
else {
|
||||
res = PyObject_IsTrue(res_obj);
|
||||
Py_DECREF(res_obj);
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue