summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2022-07-23 11:09:10 (GMT)
committerGitHub <noreply@github.com>2022-07-23 11:09:10 (GMT)
commitf15be2fad115ebe1cafc6fa372cc517ba7065ecf (patch)
tree802ae311624c50224708c1c4ccfb799fc1255290 /Modules
parent0d688bd2b6f572afb9783c3520345c9accc0ca6c (diff)
downloadcpython-f15be2fad115ebe1cafc6fa372cc517ba7065ecf.zip
cpython-f15be2fad115ebe1cafc6fa372cc517ba7065ecf.tar.gz
cpython-f15be2fad115ebe1cafc6fa372cc517ba7065ecf.tar.bz2
gh-90473: Check for HAVE_KILL in main.c:exit_sigint (GH-95165)
(cherry picked from commit d291a82df33cd8c917a374fef2a2373beda78b77) Co-authored-by: Christian Heimes <christian@python.org>
Diffstat (limited to 'Modules')
-rw-r--r--Modules/main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/main.c b/Modules/main.c
index cca669b..6904e3f 100644
--- a/Modules/main.c
+++ b/Modules/main.c
@@ -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 {