diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2010-06-23 12:48:27 +0200 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2010-06-23 12:48:27 +0200 |
commit | f48128f34a17aae7e7b9405fe32b396db45443ca (patch) | |
tree | a122a65d4a2495570b5d8662fd75a1104cb0c521 /runtime/rule.c | |
parent | d6a3b08f56cc608bc832251cd49e86e71d9574dc (diff) | |
download | rsyslog-f48128f34a17aae7e7b9405fe32b396db45443ca.tar.gz rsyslog-f48128f34a17aae7e7b9405fe32b396db45443ca.tar.bz2 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/rule.c')
-rw-r--r-- | runtime/rule.c | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/runtime/rule.c b/runtime/rule.c index 453e631d..c3c974bf 100644 --- a/runtime/rule.c +++ b/runtime/rule.c @@ -101,6 +101,7 @@ DEFFUNC_llExecFunc(processBatchDoActions) assert(pAction != NULL); +#warning execonly when prev suspended functionality missing! #if 0 // TODO: move this to the action object if((pAction->bExecWhenPrevSusp == 1) && (pDoActData->bPrevWasSuspended == 0)) { dbgprintf("not calling action because the previous one is not suspended\n"); @@ -108,20 +109,8 @@ DEFFUNC_llExecFunc(processBatchDoActions) } #endif -#if 1 - // NEW (potentially): - iRetMod = doSubmitToActionQBatch(pAction, (batch_t*) pParam); -#else - // old code -- milestone check - int i; - for(i = 0 ; i < batchNumMsgs(pBatch) && !*(pBatch->pbShutdownImmediate) ; ++i) { -dbgprintf("ZZZ: inside processBatchDoActions, processing elem %d/%d\n", i, batchNumMsgs(pBatch)); - if(pBatch->pElem[i].bFilterOK) { - iRetMod = pAction->submitToActQ(pAction, (msg_t*)(pBatch->pElem[i].pUsrp)); - } - } -#endif - //end old code + iRetMod = pAction->submitToActQ(pAction, pBatch); + #if 0 // TODO: this must be done inside the action as well! if(iRetMod == RS_RET_DISCARDMSG) { ABORT_FINALIZE(RS_RET_DISCARDMSG); |