]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[3.13] gh-140306: Clear uncaught exception info after applying error in subinterprete...
authorShamil <ashm.tech@proton.me>
Mon, 12 Jan 2026 16:19:57 +0000 (19:19 +0300)
committerGitHub <noreply@github.com>
Mon, 12 Jan 2026 16:19:57 +0000 (18:19 +0200)
Python/crossinterp.c

index caa1cb6702b8a6d887fcfc150fe207dffc616d2b..d150c6e03c080afa5b888fc91df340f64259af69 100644 (file)
@@ -1692,6 +1692,7 @@ _PyXI_ApplyCapturedException(_PyXI_session *session)
     assert(session->error != NULL);
     PyObject *res = _PyXI_ApplyError(session->error);
     assert((res == NULL) != (PyErr_Occurred() == NULL));
+    _PyXI_excinfo_Clear(&session->error->uncaught);
     session->error = NULL;
     return res;
 }