Description: kill: Correctly handle negative pids
 kill was using the wrong argv to work out what pid to kill when using
 negative pids.
Author:	Érico Rolim
Origin: upstream, https://gitlab.com/procps-ng/procps/-/merge_requests/139
Bug: https://gitlab.com/procps-ng/procps/-/issues/211
Bug-Debian: https://bugs.debian.org/1005376
Applied-Upstream: https://gitlab.com/procps-ng/procps/-/commit/79097e55e4b08ec8c1de8332e32cf03c4be1d4ec
Reviewed-by: Craig Small <csmall@debian.org>
Last-Update: 2022-03-07
--- a/skill.c
+++ b/skill.c
@@ -507,7 +507,7 @@
 			} else {
 			    /* Special case for signal digit negative
 			     * PIDs */
-			    pid = atoi(argv[optind-1]);
+			    pid = atoi(argv[optind]);
 			    if (kill((pid_t)pid, signo) != 0)
 				exitvalue = EXIT_FAILURE;
 			    exit(exitvalue);
