diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2013-11-03 10:43:44 +0100 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2013-11-03 10:43:44 +0100 |
commit | 094ae94c861fe4f0ab36bfb35a7fb3a101fd667a (patch) | |
tree | f3e60a1a335d5d16538564e236906dbafb6f303f | |
parent | d200ef2d8b3c4cd5f1f19b94fcec614c9494f28a (diff) | |
download | rsyslog-094ae94c861fe4f0ab36bfb35a7fb3a101fd667a.tar.gz rsyslog-094ae94c861fe4f0ab36bfb35a7fb3a101fd667a.tar.bz2 rsyslog-094ae94c861fe4f0ab36bfb35a7fb3a101fd667a.zip |
remove no longer needed vars from batch structure
-rw-r--r-- | runtime/batch.h | 12 | ||||
-rw-r--r-- | runtime/queue.c | 4 |
2 files changed, 1 insertions, 15 deletions
diff --git a/runtime/batch.h b/runtime/batch.h index 75eecdb1..fac0158e 100644 --- a/runtime/batch.h +++ b/runtime/batch.h @@ -46,16 +46,6 @@ typedef unsigned char batch_state_t; */ struct batch_obj_s { msg_t *pMsg; - /* work variables for action processing; these are reused for each action (or block of - * actions) - */ - /* following are caches to save allocs if not absolutely necessary */ - uchar *staticActStrings[CONF_OMOD_NUMSTRINGS_MAXSIZE]; /**< for strings */ - /* a cache to save malloc(), if not absolutely necessary */ - void *staticActParams[CONF_OMOD_NUMSTRINGS_MAXSIZE]; /**< for anything else */ - size_t staticLenStrings[CONF_OMOD_NUMSTRINGS_MAXSIZE]; - /* and the same for the message length (if used) */ - /* end action work variables */ }; /* the batch @@ -151,7 +141,7 @@ batchFree(batch_t *pBatch) { /* staticActParams MUST be freed immediately (if required), * so we do not need to do that! */ - free(pBatch->pElem[i].staticActStrings[j]); + //TODO: do this in wti! free(pBatch->pElem[i].staticActStrings[j]); } } free(pBatch->pElem); diff --git a/runtime/queue.c b/runtime/queue.c index 968c016e..93661e41 100644 --- a/runtime/queue.c +++ b/runtime/queue.c @@ -987,10 +987,6 @@ static rsRetVal qAddDirect(qqueue_t *pThis, msg_t* pMsg, wti_t *pWti) singleBatch.eltState = &batchState; singleBatch.active = &active; iRet = pThis->pConsumer(pThis->pAction, &singleBatch, pWti, &pThis->bShutdownImmediate); - /* delete the batch string params: TODO: create its own "class" for this */ - for(i = 0 ; i < CONF_OMOD_NUMSTRINGS_MAXSIZE ; ++i) { - free(batchObj.staticActStrings[i]); - } msgDestruct(&pMsg); RETiRet; |