mirror of
https://github.com/python/cpython.git
synced 2025-09-26 10:19:53 +00:00
gh-95369: add missing decref in error case of exception group's split (GH-95370)
This commit is contained in:
parent
b946f529ef
commit
bceb197947
1 changed files with 1 additions and 0 deletions
|
@ -1106,6 +1106,7 @@ exceptiongroup_split_recursive(PyObject *exc,
|
||||||
assert(PyList_CheckExact(match_list));
|
assert(PyList_CheckExact(match_list));
|
||||||
if (PyList_Append(match_list, rec_result.match) < 0) {
|
if (PyList_Append(match_list, rec_result.match) < 0) {
|
||||||
Py_DECREF(rec_result.match);
|
Py_DECREF(rec_result.match);
|
||||||
|
Py_XDECREF(rec_result.rest);
|
||||||
goto done;
|
goto done;
|
||||||
}
|
}
|
||||||
Py_DECREF(rec_result.match);
|
Py_DECREF(rec_result.match);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue