From 5ba8b2c77c3971a69bde54f3dd0ede81e641d798 Mon Sep 17 00:00:00 2001 From: Rainer Gerhards Date: Fri, 4 Apr 2008 12:35:28 +0000 Subject: cleanup --- queue.c | 9 ++------- syslogd.c | 10 ++++------ 2 files changed, 6 insertions(+), 13 deletions(-) diff --git a/queue.c b/queue.c index 7456f4a6..0828cc1d 100644 --- a/queue.c +++ b/queue.c @@ -1416,12 +1416,10 @@ queueDequeueConsumable(queue_t *pThis, wti_t *pWti, int iCancelStateSave) * on the nail [exact value]) -- rgerhards, 2008-03-14 */ if(iQueueSize < pThis->iFullDlyMrk) { -dbgoprint((obj_t*) pThis, "queue size %d below FullDlyMrk %d\n", iQueueSize, pThis->iFullDlyMrk); pthread_cond_broadcast(&pThis->belowFullDlyWtrMrk); } if(iQueueSize < pThis->iLightDlyMrk) { -dbgoprint((obj_t*) pThis, "queue size %d below LightDlyMrk %d\n", iQueueSize, pThis->iLightDlyMrk); pthread_cond_broadcast(&pThis->belowLightDlyWtrMrk); } @@ -1455,9 +1453,9 @@ finalize_it: } -/* The rate limiter - we only need one - do we? +/* The rate limiter * -* Here we may wait if a dequeue time window is defined or if we are + * Here we may wait if a dequeue time window is defined or if we are * rate-limited. TODO: If we do so, we should also look into the * way new worker threads are spawned. Obviously, it doesn't make much * sense to spawn additional worker threads when none of them can do any @@ -1506,13 +1504,11 @@ queueRateLimiter(queue_t *pThis) dbgoprint((obj_t*) pThis, "entering rate limiter\n"); iDelay = 0; -dbgprintf("deq win from %d to %d\n", pThis->iDeqtWinFromHr, pThis->iDeqtWinToHr); if(pThis->iDeqtWinToHr != 25) { /* 25 means disabled */ /* time calls are expensive, so only do them when needed */ time(&tCurr); localtime_r(&tCurr, &m); iHrCurr = m.tm_hour; -RUNLOG_VAR("%d", iHrCurr); if(pThis->iDeqtWinToHr < pThis->iDeqtWinFromHr) { if(iHrCurr < pThis->iDeqtWinToHr || iHrCurr > pThis->iDeqtWinFromHr) { @@ -1550,7 +1546,6 @@ RUNLOG_VAR("%d", iHrCurr); srSleep(iDelay, 0); } - dbgoprint((obj_t*) pThis, "rate limiter returns with iRet %d\n", iRet); RETiRet; } diff --git a/syslogd.c b/syslogd.c index d2f3e3b6..904bdbd3 100644 --- a/syslogd.c +++ b/syslogd.c @@ -3193,11 +3193,9 @@ int realMain(int argc, char **argv) } } - /* Convert to lower case to recognize the correct domain laterly - */ - for (p = (char *)LocalDomain; *p ; p++) - if (isupper((int) *p)) - *p = (char)tolower((int)*p); + /* Convert to lower case to recognize the correct domain laterly */ + for (p = (char *)LocalDomain ; *p ; p++) + *p = (char)tolower((int)*p); /* initialize the objects */ if((iRet = modInitIminternal()) != RS_RET_OK) { @@ -3215,7 +3213,7 @@ int realMain(int argc, char **argv) /* END core initializations - we now come back to carrying out command line options*/ while((iRet = bufOptRemove(&ch, &arg)) == RS_RET_OK) { -dbgprintf("deque option %c, optarg '%s'\n", ch, arg); + dbgprintf("deque option %c, optarg '%s'\n", ch, arg); switch((char)ch) { case '4': family = PF_INET; -- cgit v1.2.3