diff options
Diffstat (limited to 'shell')
-rw-r--r-- | shell/ash.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/shell/ash.c b/shell/ash.c index 2146349..0cdfd2b 100644 --- a/shell/ash.c +++ b/shell/ash.c @@ -6683,10 +6683,10 @@ sprint_status(char *s, int status, int sigonly) col = 0; st = WEXITSTATUS(status); if (!WIFEXITED(status)) { - st = WSTOPSIG(status); + st = WTERMSIG(status); #if JOBS - if (!WIFSTOPPED(status)) - st = WTERMSIG(status); + if (WIFSTOPPED(status)) + st = WSTOPSIG(status); #endif if (sigonly) { if (st == SIGINT || st == SIGPIPE) |