[Toybox] Fix, killall is not allowed to kill itself

David Seikel onefang at gmail.com
Sun Dec 16 09:31:49 PST 2012


On Sun, 16 Dec 2012 16:54:24 +0100 Elie De Brauwer
<eliedebrauwer at gmail.com> wrote:

> The LSB specification of killall says "A killall process never kills 
> itself (but may kill other killall processes)."
> 
> The current implementation of killall does not adhere to this rule,
> with the patch in attach killall will adhere to this rule.
> 
> Before:
> edb at lapedb:~/edb-stuff/toybox/toybox$ ./toybox killall -9 toybox
> Killed
> 
> After:
> edb at lapedb:~/edb-stuff/toybox/toybox$ ./toybox killall -9 toybox
> killall: No such process

It's 3AM and way past my bed time, but after it's run out of things to
kill, it just kills itself.  Seems pointless to not allow suicide on
something that will just suicide anyway, but I need sleep.

Like rm'ing something that does not exist, the end result is the same,
except for the useless error.  The thing does not exist, killall is no
longer running.  The error message is superfluous, as the result you
wanted is exactly what you get.

-- 
A big old stinking pile of genius that no one wants
coz there are too many silver coated monkeys in the world.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://lists.landley.net/pipermail/toybox-landley.net/attachments/20121217/1fd9bfc6/attachment-0002.sig>


More information about the Toybox mailing list