summaryrefslogtreecommitdiffstats
path: root/runtime/ruleset.c
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2010-06-23 12:48:27 +0200
committerRainer Gerhards <rgerhards@adiscon.com>2010-06-23 12:48:27 +0200
commitf48128f34a17aae7e7b9405fe32b396db45443ca (patch)
treea122a65d4a2495570b5d8662fd75a1104cb0c521 /runtime/ruleset.c
parentd6a3b08f56cc608bc832251cd49e86e71d9574dc (diff)
downloadrsyslog-f48128f34a17aae7e7b9405fe32b396db45443ca.tar.gz
rsyslog-f48128f34a17aae7e7b9405fe32b396db45443ca.tar.xz
rsyslog-f48128f34a17aae7e7b9405fe32b396db45443ca.zip
fixed a couple of regressions
by implementing some code that was missing so far ;) as well as finding some real bugs. I also did some general cleanup, removing debug strings and such. This code should be fairly OK to use, except when "exec only when previous action was suspended" is used -- this is NOT yet re-implemented in the tuned engine.
Diffstat (limited to 'runtime/ruleset.c')
-rw-r--r--runtime/ruleset.c11
1 files changed, 0 insertions, 11 deletions
diff --git a/runtime/ruleset.c b/runtime/ruleset.c
index 31c2e1a7..8d6a1c2f 100644
--- a/runtime/ruleset.c
+++ b/runtime/ruleset.c
@@ -175,7 +175,6 @@ processBatchMultiRuleset(batch_t *pBatch)
CHKiRet(batchInit(&snglRuleBatch, pBatch->nElem));
snglRuleBatch.pbShutdownImmediate = pBatch->pbShutdownImmediate;
-dbgprintf("ZZZ: multi-ruleset batch of %d elements must be processed\n", pBatch->nElem);
while(1) { /* loop broken inside */
/* search for first unprocessed element */
for(iStart = 0 ; iStart < pBatch->nElem && pBatch->pElem[iStart].state == BATCH_STATE_DISC ; ++iStart)
@@ -189,7 +188,6 @@ dbgprintf("ZZZ: multi-ruleset batch of %d elements must be processed\n", pBatch-
iNew = 0;
for(i = iStart ; i < pBatch->nElem ; ++i) {
if(batchElemGetRuleset(pBatch, i) == currRuleset) {
-dbgprintf("ZZZ: proc elem %d:'%s'\n", i, ((msg_t*)(pBatch->pElem[i].pUsrp))->szRawMsg+15);
batchCopyElem(&(snglRuleBatch.pElem[iNew++]), &(pBatch->pElem[i]));
/* We indicate the element also as done, so it will not be processed again */
pBatch->pElem[i].state = BATCH_STATE_DISC;
@@ -199,15 +197,6 @@ dbgprintf("ZZZ: proc elem %d:'%s'\n", i, ((msg_t*)(pBatch->pElem[i].pUsrp))->szR
batchSetSingleRuleset(&snglRuleBatch, 1);
/* process temp batch */
processBatch(&snglRuleBatch);
-
-#if 0
-for(i = iStart ; i < pBatch->nElem ; ++i) {
- dbgprintf("ZZZ: after partial execution item %d state %d\n", i, pBatch->pElem[i].state);
-}
-//dbgprintf("ZZZ: search item %d: state %d, bFilterOK %d, IsValid %d, msg:%s\n",
-//iStart, pBatch->pElem[iStart].state, pBatch->pElem[iStart].bFilterOK, batchIsValidElem(pBatch, iStart),
-//((msg_t*)(pBatch->pElem[iStart].pUsrp))->szRawMsg+40);
-#endif
}
batchFree(&snglRuleBatch);