1
0
mirror of https://github.com/systemd/systemd.git synced 2024-10-28 11:55:44 +03:00

killall: filter out bogus PIDs

we might as well filter these too since negative PIDs have special
semantics in kill(), and we should never trigger that...
This commit is contained in:
Lennart Poettering 2018-09-24 19:04:44 +02:00
parent e45154c770
commit 20ca2d10bd

View File

@ -29,7 +29,7 @@ static bool ignore_proc(pid_t pid, bool warn_rootfs) {
int r;
/* We are PID 1, let's not commit suicide */
if (pid == 1)
if (pid <= 1)
return true;
/* Ignore kernel threads */