From b66090ce4f5bd7fb19e66ac09ac8e3f5cb1ca83e Mon Sep 17 00:00:00 2001 From: Joachim Nilsson Date: Mon, 28 Oct 2019 20:42:40 +0100 Subject: [PATCH] Minor, sync variable name with FreeBSD Signed-off-by: Joachim Nilsson --- src/syslogd.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/syslogd.c b/src/syslogd.c index dd15d5b..9f7b01b 100644 --- a/src/syslogd.c +++ b/src/syslogd.c @@ -334,7 +334,8 @@ struct code FacNames[] = { { NULL, -1 }, }; -int Debug; /* debug flag */ +static int Debug; /* debug flag */ +static int Foreground = 0; /* don't fork - don't run in daemon mode */ char LocalHostName[MAXHOSTNAMELEN + 1]; /* our hostname */ char *LocalDomain; /* our local domain name */ char *emptystring = ""; @@ -467,7 +468,7 @@ int main(int argc, char *argv[]) break; case 'n': /* don't fork */ - NoFork = 1; + Foreground = 1; break; case 'p': /* path to regular log socket */ @@ -505,7 +506,7 @@ int main(int argc, char *argv[]) usage(1); #ifndef TESTING - if (!(Debug || NoFork)) { + if ((!Foreground) && (!Debug)) { logit("Checking pidfile.\n"); if (!check_pid(PidFile)) { signal(SIGTERM, doexit);