mirror of
https://github.com/python/cpython.git
synced 2025-08-03 08:34:29 +00:00
bpo-37933: Fix faulthandler.cancel_dump_traceback_later() (GH-15440)
Fix faulthandler.cancel_dump_traceback_later() call if cancel_dump_traceback_later() was not called previously.
This commit is contained in:
parent
88ea166dad
commit
e278335a6e
2 changed files with 16 additions and 0 deletions
|
@ -631,6 +631,11 @@ faulthandler_thread(void *unused)
|
|||
static void
|
||||
cancel_dump_traceback_later(void)
|
||||
{
|
||||
/* If not scheduled, nothing to cancel */
|
||||
if (!thread.cancel_event) {
|
||||
return;
|
||||
}
|
||||
|
||||
/* Notify cancellation */
|
||||
PyThread_release_lock(thread.cancel_event);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue