diff options
author | Brandt Bucher <brandtbucher@microsoft.com> | 2023-01-09 20:20:04 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-09 20:20:04 (GMT) |
commit | 61762b93871419b34f02d83cee5ca0d94d4a2903 (patch) | |
tree | 286b9aff961b5435e2d34894857a603ae86aa5c6 /Objects/frameobject.c | |
parent | 2e80c2a976c13dcb69a654b386164dca362295a3 (diff) | |
download | cpython-61762b93871419b34f02d83cee5ca0d94d4a2903.zip cpython-61762b93871419b34f02d83cee5ca0d94d4a2903.tar.gz cpython-61762b93871419b34f02d83cee5ca0d94d4a2903.tar.bz2 |
GH-100126: Skip incomplete frames in more places (GH-100613)
Diffstat (limited to 'Objects/frameobject.c')
-rw-r--r-- | Objects/frameobject.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/Objects/frameobject.c b/Objects/frameobject.c index ebe3bfe..39ccca7 100644 --- a/Objects/frameobject.c +++ b/Objects/frameobject.c @@ -1405,9 +1405,7 @@ PyFrame_GetBack(PyFrameObject *frame) PyFrameObject *back = frame->f_back; if (back == NULL) { _PyInterpreterFrame *prev = frame->f_frame->previous; - while (prev && _PyFrame_IsIncomplete(prev)) { - prev = prev->previous; - } + prev = _PyFrame_GetFirstComplete(prev); if (prev) { back = _PyFrame_GetFrameObject(prev); } |