mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 15:40:19 +00:00
Shell: Don't spam perror() on kill_job()
That function is allowed to be given a dead job, so don't bother with perror()
This commit is contained in:
parent
86f50aa74e
commit
cb29dca029
Notes:
sideshowbarker
2024-07-18 23:03:32 +09:00
Author: https://github.com/alimpfard Commit: https://github.com/SerenityOS/serenity/commit/cb29dca0293 Pull-request: https://github.com/SerenityOS/serenity/pull/4996
1 changed files with 2 additions and 1 deletions
|
@ -1833,7 +1833,8 @@ void Shell::kill_job(const Job* job, int sig)
|
|||
|
||||
if (killpg(job->pgid(), sig) < 0) {
|
||||
if (kill(job->pid(), sig) < 0) {
|
||||
perror("kill");
|
||||
if (errno != ESRCH)
|
||||
perror("kill");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue