Skip to content

Commit

Permalink
gh-90473: Check for HAVE_KILL in main.c:exit_sigint (GH-95165)
Browse files Browse the repository at this point in the history
(cherry picked from commit d291a82)

Co-authored-by: Christian Heimes <[email protected]>
  • Loading branch information
miss-islington and tiran authored Jul 23, 2022
1 parent 0d688bd commit f15be2f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Modules/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -640,7 +640,7 @@ exit_sigint(void)
* SIG_DFL handler for SIGINT if KeyboardInterrupt went unhandled.
* If we don't, a calling process such as a shell may not know
* about the user's ^C. https://www.cons.org/cracauer/sigint.html */
#if defined(HAVE_GETPID) && !defined(MS_WINDOWS)
#if defined(HAVE_GETPID) && defined(HAVE_KILL) && !defined(MS_WINDOWS)
if (PyOS_setsig(SIGINT, SIG_DFL) == SIG_ERR) {
perror("signal"); /* Impossible in normal environments. */
} else {
Expand Down

0 comments on commit f15be2f

Please sign in to comment.