Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 16 Jul 2014 10:37:05 +0000 (UTC)
From:      Baptiste Daroussin <bapt@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r268747 - head/usr.bin/timeout
Message-ID:  <201407161037.s6GAb5vB003611@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bapt
Date: Wed Jul 16 10:37:05 2014
New Revision: 268747
URL: http://svnweb.freebsd.org/changeset/base/268747

Log:
  Fix build with gcc

Modified:
  head/usr.bin/timeout/timeout.c

Modified: head/usr.bin/timeout/timeout.c
==============================================================================
--- head/usr.bin/timeout/timeout.c	Wed Jul 16 10:34:55 2014	(r268746)
+++ head/usr.bin/timeout/timeout.c	Wed Jul 16 10:37:05 2014	(r268747)
@@ -102,11 +102,11 @@ static int
 parse_signal(const char *str)
 {
 	int sig, i;
-	const char *err;
+	const char *errstr;
 
-	sig = strtonum(str, 0, sys_nsig, &err);
+	sig = strtonum(str, 0, sys_nsig, &errstr);
 
-	if (err == NULL)
+	if (errstr == NULL)
 		return (sig);
 	if (strncasecmp(str, "SIG", 3) == 0)
 		str += 3;
@@ -166,7 +166,6 @@ main(int argc, char **argv)
 	int foreground, preserve;
 	int error, pstat, status;
 	int killsig = SIGTERM;
-	int killedwith;
 	pid_t pgid, pid, cpid;
 	double first_kill;
 	double second_kill;
@@ -186,6 +185,7 @@ main(int argc, char **argv)
 	foreground = preserve = 0;
 	second_kill = 0;
 	cpid = -1;
+	pgid = -1;
 
 	struct option longopts[] = {
 		{ "preserve-status", no_argument,       &preserve,    1 },
@@ -273,7 +273,6 @@ main(int argc, char **argv)
 	sigemptyset(&signals.sa_mask);
 
 	for (;;) {
-		killedwith = killsig;
 		sigemptyset(&signals.sa_mask);
 		sigsuspend(&signals.sa_mask);
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201407161037.s6GAb5vB003611>