diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2012-09-25 15:35:08 +0200 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2012-09-25 15:35:08 +0200 |
commit | c030585a630902ddd56b303ede1bfd8612036579 (patch) | |
tree | 794d459843bb7b2b535217ff9d5cccabff37eae6 /runtime | |
parent | 9edcc0b6b286b2e0223d32fd7fd6bd66a405f2eb (diff) | |
download | rsyslog-c030585a630902ddd56b303ede1bfd8612036579.tar.gz rsyslog-c030585a630902ddd56b303ede1bfd8612036579.tar.bz2 rsyslog-c030585a630902ddd56b303ede1bfd8612036579.zip |
fix invalid state handling during action execution
could lead to execution of not-to-be-executed action. very recent regression.
Diffstat (limited to 'runtime')
-rw-r--r-- | runtime/batch.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/runtime/batch.h b/runtime/batch.h index fdacb8e2..f743c188 100644 --- a/runtime/batch.h +++ b/runtime/batch.h @@ -129,8 +129,8 @@ batchSetElemState(batch_t *pBatch, int i, batch_state_t newState) { */ static inline int batchIsValidElem(batch_t *pBatch, int i) { - return( (pBatch->active == NULL || pBatch->active[i]) - && pBatch->pElem[i].state != BATCH_STATE_DISC); + return( (pBatch->pElem[i].state != BATCH_STATE_DISC) + && (pBatch->active == NULL || pBatch->active[i])); } |