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.
This commit is contained in:
5
script.c
5
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;
|
||||
}
|
||||
|
Reference in New Issue
Block a user