diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2011-04-27 17:57:47 +0200 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2011-04-27 17:57:47 +0200 |
commit | 6093f3110306e0575d10d09807da1e6895af4eba (patch) | |
tree | ec25293b4cb9c4c88799538609c15fae726f73cc /tools/syslogd.c | |
parent | ee346d8aec05bc79600f7d5280d88ab45d2bcab5 (diff) | |
download | rsyslog-6093f3110306e0575d10d09807da1e6895af4eba.tar.gz rsyslog-6093f3110306e0575d10d09807da1e6895af4eba.tar.xz rsyslog-6093f3110306e0575d10d09807da1e6895af4eba.zip |
step: moved main message queue activation to after priv drop
Diffstat (limited to 'tools/syslogd.c')
-rw-r--r-- | tools/syslogd.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/tools/syslogd.c b/tools/syslogd.c index dcce4d77..4fe6fa26 100644 --- a/tools/syslogd.c +++ b/tools/syslogd.c @@ -231,7 +231,7 @@ int iCompatibilityMode = 0; /* version we should be compatible with; 0 means sy int MarkInterval = 20 * 60; /* interval between marks in seconds - read-only after startup */ int send_to_all = 0; /* send message to all IPv4/IPv6 addresses */ static int NoFork = 0; /* don't fork - don't run in daemon mode - read-only after startup */ -static int bHaveMainQueue = 0;/* set to 1 if the main queue - in queueing mode - is available +int bHaveMainQueue = 0;/* set to 1 if the main queue - in queueing mode - is available * If the main queue is either not yet ready or not running in * queueing mode (mode DIRECT!), then this is set to 0. */ @@ -1308,17 +1308,6 @@ init(void) legacyOptsHook(); - - /* create message queue */ - CHKiRet_Hdlr(createMainQueue(&pMsgQueue, UCHAR_CONSTANT("main Q"))) { - /* no queue is fatal, we need to give up in that case... */ - fprintf(stderr, "fatal error %d: could not create message queue - rsyslogd can not run!\n", iRet); - exit(1); - } - - bHaveMainQueue = (ourConf->globals.mainQ.MainMsgQueType == QUEUETYPE_DIRECT) ? 0 : 1; - DBGPRINTF("Main processing queue is initialized and running\n"); - memset(&sigAct, 0, sizeof (sigAct)); sigemptyset(&sigAct.sa_mask); sigAct.sa_handler = sighup_handler; |