From 09a7bb78fec94c3f9f14d82bb65408fc37d64ad6 Mon Sep 17 00:00:00 2001 From: "Todd C. Miller" Date: Sun, 11 Oct 2009 12:42:03 +0000 Subject: [PATCH] Apparently we need to send SIGSTOP to the command as well as ourself when we get SIGTSTP, the kernel doesn't automatically stop the process for us. --- script.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/script.c b/script.c index abc08ec1a..b6dffe5e5 100644 --- a/script.c +++ b/script.c @@ -794,9 +794,8 @@ sigrelay(signo) } /* Relay signal back to parent for its tty. */ kill(parent, signo); - /* Suspend self, parent will continue us when it is time. */ - /* XXX - want to be able to handle SIGSTOP too */ - kill(getpid(), SIGSTOP); + /* Suspend self and command, parent will continue us when it is time. */ + killpg(getpid(), SIGSTOP); errno = serrno; } -- 2.40.0