summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2009-05-28 15:57:39 +0200
committerRainer Gerhards <rgerhards@adiscon.com>2009-05-28 15:57:39 +0200
commitcbbf1586a204a897a050b6cb294b120e3ff5f23c (patch)
tree2eb542dbfa702bdf8e560ab808caf4cc6ba7495b
parent7860e4a393995662e5f82f0ecbb84dd28c7f0297 (diff)
downloadrsyslog-cbbf1586a204a897a050b6cb294b120e3ff5f23c.tar.gz
rsyslog-cbbf1586a204a897a050b6cb294b120e3ff5f23c.tar.xz
rsyslog-cbbf1586a204a897a050b6cb294b120e3ff5f23c.zip
some cleanup & fix make distcheck
-rw-r--r--runtime/debug.h4
-rw-r--r--runtime/queue.c17
-rw-r--r--tests/Makefile.am2
-rw-r--r--tests/testsuites/arrayqueue.conf2
-rw-r--r--tests/testsuites/da-mainmsg-q.conf2
-rw-r--r--tests/testsuites/linkedlistqueue.conf2
6 files changed, 9 insertions, 20 deletions
diff --git a/runtime/debug.h b/runtime/debug.h
index 03702250..8b66d784 100644
--- a/runtime/debug.h
+++ b/runtime/debug.h
@@ -134,8 +134,8 @@ void dbgPrintAllDebugInfo(void);
/* debug aides */
-//#ifdef RTINST
-#if 1 // temporarily removed for helgrind
+#ifdef RTINST
+//#if 0 // temporarily removed for helgrind
#define d_pthread_mutex_lock(x) dbgMutexLock(x, pdbgFuncDB, __LINE__, dbgCALLStaCK_POP_POINT )
#define d_pthread_mutex_trylock(x) dbgMutexTryLock(x, pdbgFuncDB, __LINE__, dbgCALLStaCK_POP_POINT )
#define d_pthread_mutex_unlock(x) dbgMutexUnlock(x, pdbgFuncDB, __LINE__, dbgCALLStaCK_POP_POINT )
diff --git a/runtime/queue.c b/runtime/queue.c
index 57385056..23d60ddc 100644
--- a/runtime/queue.c
+++ b/runtime/queue.c
@@ -54,7 +54,7 @@
#include "wtp.h"
#include "wti.h"
#include "atomic.h"
-#include "msg.h" /* TODO: remove one we removed MsgAddRef() call */
+#include "msg.h" /* TODO: remove once we remove MsgAddRef() call */
#ifdef OS_SOLARIS
# include <sched.h>
@@ -297,11 +297,6 @@ TurnOffDAMode(qqueue_t *pThis)
ISOBJ_TYPE_assert(pThis, qqueue);
ASSERT(pThis->bRunsDA);
- /* at this point, we need a fully initialized DA queue. So if it isn't, we finally need
- * to wait for its startup... -- rgerhards, 2008-01-25
- */
- //TODO: MULTI del, can not happen (but verify first) qqueueWaitDAModeInitialized(pThis);
-
/* if we need to pull any data that we still need from the (child) disk queue,
* now would be the time to do so. At present, we do not need this, but I'd like to
* keep that comment if future need arises.
@@ -865,8 +860,7 @@ qqueueTryLoadPersistedInfo(qqueue_t *pThis)
CHKiRet(obj.Deserialize(&pThis->tVars.disk.pReadDel, (uchar*) "strm", psQIF,
(rsRetVal(*)(obj_t*,void*))qqueueLoadPersStrmInfoFixup, pThis));
- /* we now need to take care of the Deq handle. It is not persisted, so we can create
- * a virgin copy based on pReadDel. // TODO duplicat code, same as blow - single function!
+ /* create a duplicate for the read "pointer".
*/
CHKiRet(strmDup(pThis->tVars.disk.pReadDel, &pThis->tVars.disk.pReadDeq));
@@ -1712,7 +1706,7 @@ DequeueConsumable(qqueue_t *pThis, wti_t *pWti, int iCancelStateSave)
pthread_cond_broadcast(&pThis->belowLightDlyWtrMrk);
}
- // TODO: MULTI: check physical queue size!
+ // TODO: MULTI: check physical queue size?
pthread_cond_signal(&pThis->notFull);
d_pthread_mutex_unlock(pThis->mut);
pthread_setcancelstate(iCancelStateSave, NULL);
@@ -1982,11 +1976,6 @@ static rsRetVal
ChkStopWrkrReg(qqueue_t *pThis)
{
DEFiRet;
- /* original condition
- return pThis->bEnqOnly || pThis->bRunsDA || (pThis->pqParent != NULL && getPhysicalQueueSize(pThis) == 0);
- * TODO: remove when verified! -- rgerhards, 2009-05-26
- */
- // TODO: DEL - we now keep the workers running! if(pThis->bEnqOnly || pThis->bRunsDA) {
if(pThis->bEnqOnly) {
dbgprintf("XXX: terminate_NOW queue:Reg worker: enqOnly! queue size %d\n", getPhysicalQueueSize(pThis));
iRet = RS_RET_TERMINATE_NOW;
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 14d15247..a0723c9d 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -43,7 +43,7 @@ EXTRA_DIST= 1.rstest 2.rstest 3.rstest err1.rstest \
testsuites/rfc5424-4.parse1 \
testsuites/omod-if-array.conf \
testsuites/1.omod-if-array \
- testsuites/1.field1-if-array \
+ testsuites/1.field1 \
killrsyslog.sh \
parsertest.sh \
fieldtest.sh \
diff --git a/tests/testsuites/arrayqueue.conf b/tests/testsuites/arrayqueue.conf
index 44b9920b..c5874a83 100644
--- a/tests/testsuites/arrayqueue.conf
+++ b/tests/testsuites/arrayqueue.conf
@@ -1,6 +1,6 @@
# Test for queue fixedArray mode (see .sh file for details)
# rgerhards, 2009-04-17
-$IncludeConfig testsuites/diag-common.conf
+$IncludeConfig diag-common.conf
$ModLoad ../plugins/imtcp/.libs/imtcp
$MainMsgQueueTimeoutShutdown 10000
diff --git a/tests/testsuites/da-mainmsg-q.conf b/tests/testsuites/da-mainmsg-q.conf
index c1e8cb01..843a3e4f 100644
--- a/tests/testsuites/da-mainmsg-q.conf
+++ b/tests/testsuites/da-mainmsg-q.conf
@@ -4,7 +4,7 @@ $ModLoad ../plugins/imtcp/.libs/imtcp
$MainMsgQueueTimeoutShutdown 10000
$InputTCPServerRun 13514
-$IncludeConfig testsuites/diag-common.conf
+$IncludeConfig diag-common.conf
# set spool locations and switch queue to disk assisted mode
$WorkDirectory test-spool
diff --git a/tests/testsuites/linkedlistqueue.conf b/tests/testsuites/linkedlistqueue.conf
index 321678a5..92a9649c 100644
--- a/tests/testsuites/linkedlistqueue.conf
+++ b/tests/testsuites/linkedlistqueue.conf
@@ -1,6 +1,6 @@
# Test for queue LinkedList mode (see .sh file for details)
# rgerhards, 2009-04-17
-$IncludeConfig testsuites/diag-common.conf
+$IncludeConfig diag-common.conf
$ModLoad ../plugins/imtcp/.libs/imtcp
$MainMsgQueueTimeoutShutdown 10000