summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--syslogd.c13
1 files changed, 1 insertions, 12 deletions
diff --git a/syslogd.c b/syslogd.c
index 53874f46..d762cf3b 100644
--- a/syslogd.c
+++ b/syslogd.c
@@ -2209,13 +2209,6 @@ void printline(char *hname, char *msg, int bParseHost)
logmsg(pri, pMsg, SYNC_FILE);
- /* rgerhards 2004-11-11:
- * we are done with the message object. If it still is
- * stored somewhere, we can call discard anyhow. This
- * is handled via the reference count - see description
- * of msg_t for details.
- */
- MsgDestruct(pMsg);
return;
}
@@ -2233,8 +2226,6 @@ logmsgInternal(int pri, char *msg, int flags)
{
msg_t *pMsg;
-dbgprintf("logmsgInternal: msg passed: '%s'\n", msg);
-
if((pMsg = MsgConstruct()) == NULL){
/* rgerhards 2004-11-09: calling panic might not be the
* brightest idea - however, it is the best I currently have
@@ -2270,7 +2261,6 @@ dbgprintf("logmsgInternal: msg passed: '%s'\n", msg);
* message to the queue engine.
*/
logmsg(pri, pMsg, flags);
- MsgDestruct(pMsg);
}
}
@@ -2718,7 +2708,7 @@ static void enqueueMsg(msg_t *pMsg)
goto unlock;
}
}
- queueAdd(fifo, MsgAddRef(pMsg));
+ queueAdd(fifo, pMsg);
unlock:
/* now activate the worker thread */
pthread_mutex_unlock(fifo->mut);
@@ -5474,7 +5464,6 @@ static void processImInternal(void)
while(iminternalRemoveMsg(&iPri, &pMsg, &iFlags) == RS_RET_OK) {
logmsg(iPri, pMsg, iFlags);
- MsgDestruct(pMsg);
}
}