aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorWilliam Hubbs <w.d.hubbs@gmail.com>2018-11-28 16:06:07 -0600
committerWilliam Hubbs <w.d.hubbs@gmail.com>2018-11-28 16:06:07 -0600
commitb7828651babd20fb6cc11aed91721e103ccbb3e1 (patch)
tree7c893fdc5eaec528004f4d516929000e4ac6568b /src
parente96f7d5658950ddee68e54fba4b6321b9a6a2ed8 (diff)
supervise-daemon: fix type of exiting flag
Diffstat (limited to 'src')
-rw-r--r--src/rc/supervise-daemon.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/rc/supervise-daemon.c b/src/rc/supervise-daemon.c
index 99159ef3..b655cd4b 100644
--- a/src/rc/supervise-daemon.c
+++ b/src/rc/supervise-daemon.c
@@ -121,6 +121,7 @@ const char *usagestring = NULL;
static int healthcheckdelay = 0;
static int healthchecktimer = 0;
static volatile sig_atomic_t do_healthcheck = 0;
+static volatile sig_atomic_t exiting = 0;
static int nicelevel = 0;
static int ionicec = -1;
static int ioniced = 0;
@@ -133,7 +134,6 @@ static int stdout_fd;
static int stderr_fd;
static char *redirect_stderr = NULL;
static char *redirect_stdout = NULL;
-static bool exiting = false;
#ifdef TIOCNOTTY
static int tty_fd = -1;
#endif
@@ -184,7 +184,7 @@ static void handle_signal(int sig)
syslog(LOG_WARNING, "caught signal %d", sig);
if (sig == SIGTERM)
- exiting = true;
+ exiting = 1;
/* Restore errno */
errno = serrno;
if (! exiting)
@@ -582,7 +582,7 @@ static void supervisor(char *exec, char **argv)
if (respawn_count > respawn_max) {
syslog(LOG_WARNING,
"respawned \"%s\" too many times, exiting", exec);
- exiting = true;
+ exiting = 1;
continue;
}
}