fix parsing of negative PIDs

Signed-off-by: Craig Small <csmall@enc.com.au>
This commit is contained in:
Benedikt Böhm authored and Craig Small committed 2016-04-17 14:59:11 +10:00
1 parent aa9bd38d0a
commit b42997b6c9
1 file changed
+1 -1
+1 -1
View File
@@ -479,7 +479,7 @@ static void __attribute__ ((__noreturn__))
} else {
/* Special case for signal digit negative
* PIDs */
pid = (long)('0' - optopt);
pid = atoi(argv[optind]);
if (kill((pid_t)pid, signo) != 0)
exitvalue = EXIT_FAILURE;
exit(exitvalue);