mirror of
https://github.com/python/cpython.git
synced 2025-08-04 17:08:35 +00:00
GH-96754: Check whether the interpreter frame is complete before creating frame object. (GH-96776)
This commit is contained in:
parent
1756ffd66a
commit
12c5f328d2
4 changed files with 14 additions and 3 deletions
|
@ -1832,6 +1832,9 @@ _PyErr_CheckSignalsTstate(PyThreadState *tstate)
|
|||
_Py_atomic_store(&is_tripped, 0);
|
||||
|
||||
_PyInterpreterFrame *frame = tstate->cframe->current_frame;
|
||||
while (frame && _PyFrame_IsIncomplete(frame)) {
|
||||
frame = frame->previous;
|
||||
}
|
||||
signal_state_t *state = &signal_global_state;
|
||||
for (int i = 1; i < Py_NSIG; i++) {
|
||||
if (!_Py_atomic_load_relaxed(&Handlers[i].tripped)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue