cvs commit: src/usr.bin/pkill pkill.c

Andrey Chernov ache at FreeBSD.ORG
Wed Nov 16 12:42:00 GMT 2005

On Wed, Nov 16, 2005 at 12:59:00PM +0100, Pawel Jakub Dawidek wrote:
> Let's say you call 'pkill sleep'. First it creates list of the matching
> processes and when the list is done, it starts killing processes from
> the list. When there is a race, so that process was inserted into the
> list, but disappeared before killing, pkill(1) will quit with an error.
> Which is bogus: there were 8 sleep processes, the 5th one disappeared,
> so first 4 was killed, last 3 are still alive and pkill(1) returned an
> error.

Well, my initial statement will be modified slightly.

1) For SIGKILL, pkill should ignore disappeared precesses, as NetBSD does.
2) For any other signal, it should issue _warning_ and not error & stop.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 305 bytes
Desc: not available
Url :

More information about the cvs-src mailing list