mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 11:18:11 +00:00
Shell: If a command process is stopped, print the stop signal to stderr
This commit is contained in:
parent
65961d3ffc
commit
7454926765
1 changed files with 1 additions and 1 deletions
|
@ -817,7 +817,7 @@ static int run_command(const String& cmd)
|
|||
if (i == 0)
|
||||
return_value = WEXITSTATUS(wstatus);
|
||||
} else if (WIFSTOPPED(wstatus)) {
|
||||
printf("Shell: %s(%d) stopped.\n", child.name.characters(), child.pid);
|
||||
fprintf(stderr, "Shell: %s(%d) %s\n", child.name.characters(), child.pid, strsignal(WSTOPSIG(wstatus)));
|
||||
} else {
|
||||
if (WIFSIGNALED(wstatus)) {
|
||||
printf("Shell: %s(%d) exited due to signal '%s'\n", child.name.characters(), child.pid, strsignal(WTERMSIG(wstatus)));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue