procps/lib
Craig Small aa41c309dd kill: -l space between name parses correctly
This was supposed to be just a cherry-pick of the referenced
commit. However there were two problems:
 1. kill code was moved out to its own file
 2. strtosig() had a latent bug where signal numbers were not
 converted to names.

Original note:
kill -lHUP would work correctly, but kill -l HUP would not.

The list option in kill was hit by a quirk of getopt_long where an
option with an optional argument would not attempt to get the argument
beyond the space, even though a mandatory argument would do that.

The fix is a kludge to scan to the next argument and if it looks
like something we can use, use it. Lucky for us, the list option is
one where parsing can stop immediately.

Thanks to Brian Vandenberg for the way forward.

References:
 http://stackoverflow.com/questions/1052746/getopt-does-not-parse-optional-arguments-to-parameters
 https://bugs.debian.org/854407
 commit 537cea324b121f54744369425332c256aa84a181
2017-05-22 22:15:59 +10:00
..
.gitignore A locale-independent strtod 2016-03-10 22:27:09 +11:00
fileutils.c
signals.c kill: -l space between name parses correctly 2017-05-22 22:15:59 +10:00
strutils.c A locale-independent strtod 2016-03-10 22:27:09 +11:00
strverscmp.c Added Cygwin build support 2016-03-12 15:07:30 +11:00
test_fileutils.c
test_process.c tests: Conditionally add prctl to test process 2016-04-17 09:11:24 +10:00
test_strtod_nol.c A locale-independent strtod 2016-03-10 22:27:09 +11:00
test_strutils.c