Patch to make killall actually kill all PIDs with the specified name,

rather then busylooping trying to kill the first one until it dies.
Should be more efficient now, and will only send one signal to each
specified process.
 -Erik
This commit is contained in:
Erik Andersen
2000-04-07 06:00:07 +00:00
parent 93d6513d93
commit 825aead68b
12 changed files with 51 additions and 34 deletions

View File

@ -28,7 +28,7 @@ extern int reboot_main(int argc, char **argv)
{
#ifdef BB_FEATURE_LINUXRC
/* don't assume init's pid == 1 */
exit(kill(findPidByName("init"), SIGINT));
exit(kill(*(findPidByName("init")), SIGINT));
#else
exit(kill(1, SIGINT));
#endif