summaryrefslogtreecommitdiff
path: root/usr.sbin/watchdogd/watchdogd.c
diff options
context:
space:
mode:
authorMarc Balmer <mbalmer@cvs.openbsd.org>2006-12-23 10:37:34 +0000
committerMarc Balmer <mbalmer@cvs.openbsd.org>2006-12-23 10:37:34 +0000
commitb97760a3d3151886153fc857b8341c5e8ba4dfdc (patch)
tree9ab0b26dbf835ea203341e89e96b531b71de22c5 /usr.sbin/watchdogd/watchdogd.c
parentcb435f1a82e36a4fc850de087d98a1d222b37756 (diff)
Do not name both a variable and a goto target 'restore'; it's legal, but
confusing. at least it confused thib...
Diffstat (limited to 'usr.sbin/watchdogd/watchdogd.c')
-rw-r--r--usr.sbin/watchdogd/watchdogd.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.sbin/watchdogd/watchdogd.c b/usr.sbin/watchdogd/watchdogd.c
index ec8c1adeeae..366cd875891 100644
--- a/usr.sbin/watchdogd/watchdogd.c
+++ b/usr.sbin/watchdogd/watchdogd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: watchdogd.c,v 1.9 2006/12/21 15:51:54 mbalmer Exp $ */
+/* $OpenBSD: watchdogd.c,v 1.10 2006/12/23 10:37:33 mbalmer Exp $ */
/*
* Copyright (c) 2005 Marc Balmer <mbalmer@openbsd.org>
@@ -56,7 +56,7 @@ main(int argc, char *argv[])
size_t len;
u_int interval = 0, period = 30, nperiod;
int ch, trigauto, sauto, speriod;
- int quiet = 0, daemonize = 1, retval = 1, restore = 1;
+ int quiet = 0, daemonize = 1, retval = 1, do_restore = 1;
int mib[3];
while ((ch = getopt(argc, argv, "di:np:q")) != -1) {
@@ -71,7 +71,7 @@ main(int argc, char *argv[])
errx(1, "interval is %s: %s", errstr, optarg);
break;
case 'n':
- restore = 0;
+ do_restore = 0;
break;
case 'p':
period = (u_int)strtonum(optarg, 2LL, 86400LL, &errstr);
@@ -147,7 +147,7 @@ main(int argc, char *argv[])
sleep(interval);
}
- if (restore) {
+ if (do_restore) {
restore: sysctl(mib, 3, NULL, 0, &speriod, sizeof(speriod));
mib[2] = KERN_WATCHDOG_AUTO;
sysctl(mib, 3, NULL, 0, &sauto, sizeof(sauto));