summaryrefslogtreecommitdiffstats
path: root/action.c
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2011-10-17 15:26:11 +0200
committerRainer Gerhards <rgerhards@adiscon.com>2011-10-17 15:26:11 +0200
commit16f06168e10d0315cc5d65516043809edd9d2232 (patch)
tree7d28755836998e5ff6a6a6f7ecea1fd0d9077a22 /action.c
parent0c7604dc27119122a3022c7bf094ffb5f8d59e6d (diff)
parentf84c8c4e9637748bd3a6a985bd12afa6b50e9797 (diff)
downloadrsyslog-16f06168e10d0315cc5d65516043809edd9d2232.tar.gz
rsyslog-16f06168e10d0315cc5d65516043809edd9d2232.tar.xz
rsyslog-16f06168e10d0315cc5d65516043809edd9d2232.zip
Merge branch 'v5-stable' into v5-devel
Conflicts: ChangeLog
Diffstat (limited to 'action.c')
-rw-r--r--action.c19
1 files changed, 9 insertions, 10 deletions
diff --git a/action.c b/action.c
index d8498739..af7723e7 100644
--- a/action.c
+++ b/action.c
@@ -772,7 +772,7 @@ finalize_it:
*/
static rsRetVal releaseBatch(action_t *pAction, batch_t *pBatch)
{
- int iArr;
+ int jArr;
int i, j;
batch_obj_t *pElem;
uchar ***ppMsgs;
@@ -786,15 +786,15 @@ static rsRetVal releaseBatch(action_t *pAction, batch_t *pBatch)
switch(pAction->eParamPassing) {
case ACT_ARRAY_PASSING:
ppMsgs = (uchar***) pElem->staticActParams;
- for(i = 0 ; i < pAction->iNumTpls ; ++i) {
- if(((uchar**)ppMsgs)[i] != NULL) {
- iArr = 0;
- while(ppMsgs[i][iArr] != NULL) {
- d_free(ppMsgs[i][iArr++]);
- ppMsgs[i][iArr++] = NULL;
+ for(j = 0 ; j < pAction->iNumTpls ; ++j) {
+ if(((uchar**)ppMsgs)[j] != NULL) {
+ jArr = 0;
+ while(ppMsgs[j][jArr] != NULL) {
+ d_free(ppMsgs[j][jArr++]);
+ ppMsgs[j][jArr++] = NULL;
}
- d_free(((uchar**)ppMsgs)[i]);
- ((uchar**)ppMsgs)[i] = NULL;
+ d_free(((uchar**)ppMsgs)[j]);
+ ((uchar**)ppMsgs)[j] = NULL;
}
}
break;
@@ -1368,7 +1368,6 @@ actionWriteToAction(action_t *pAction)
DBGPRINTF("action not yet ready again to be executed, onceInterval %d, tCurr %d, tNext %d\n",
(int) pAction->iSecsExecOnceInterval, (int) getActNow(pAction),
(int) (pAction->iSecsExecOnceInterval + pAction->tLastExec));
- pAction->tLastExec = getActNow(pAction); /* re-init time flags */
FINALIZE;
}