daemon: make log_reopen variable a bool
Following style(9) and C99 recommendation use bool instead of int for boolean operations. Reviewed by: kevans Pull Request: https://github.com/freebsd/freebsd-src/pull/669
This commit is contained in:
parent
f2f9d31d9f
commit
97022e90c3
@ -144,6 +144,7 @@ main(int argc, char *argv[])
|
|||||||
{
|
{
|
||||||
bool supervision_enabled = false;
|
bool supervision_enabled = false;
|
||||||
bool syslog_enabled = false;
|
bool syslog_enabled = false;
|
||||||
|
bool log_reopen = false;
|
||||||
char *p = NULL;
|
char *p = NULL;
|
||||||
const char *pidfile = NULL;
|
const char *pidfile = NULL;
|
||||||
const char *logtag = "daemon";
|
const char *logtag = "daemon";
|
||||||
@ -153,7 +154,6 @@ main(int argc, char *argv[])
|
|||||||
const char *user = NULL;
|
const char *user = NULL;
|
||||||
int ch = 0;
|
int ch = 0;
|
||||||
int child_eof = 0;
|
int child_eof = 0;
|
||||||
int log_reopen = 0;
|
|
||||||
int logfac = LOG_DAEMON;
|
int logfac = LOG_DAEMON;
|
||||||
int logpri = LOG_NOTICE;
|
int logpri = LOG_NOTICE;
|
||||||
int nochdir = 1;
|
int nochdir = 1;
|
||||||
@ -184,7 +184,7 @@ main(int argc, char *argv[])
|
|||||||
noclose = 0;
|
noclose = 0;
|
||||||
break;
|
break;
|
||||||
case 'H':
|
case 'H':
|
||||||
log_reopen = 1;
|
log_reopen = true;
|
||||||
break;
|
break;
|
||||||
case 'l':
|
case 'l':
|
||||||
logfac = get_log_mapping(optarg, facilitynames);
|
logfac = get_log_mapping(optarg, facilitynames);
|
||||||
|
Loading…
Reference in New Issue
Block a user