summaryrefslogtreecommitdiffstats
path: root/plugins/imuxsock
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2012-06-25 12:35:46 +0200
committerRainer Gerhards <rgerhards@adiscon.com>2012-06-25 12:35:46 +0200
commitbf85d81790a26945e404c6fdfdddad5eadbaa371 (patch)
tree5b9e97ea2c78e9450f58971ecae3234ba7eb3c85 /plugins/imuxsock
parent4b150db338ae885ea3a3bb7cc5b5f84e2fc96e89 (diff)
downloadrsyslog-bf85d81790a26945e404c6fdfdddad5eadbaa371.tar.gz
rsyslog-bf85d81790a26945e404c6fdfdddad5eadbaa371.tar.xz
rsyslog-bf85d81790a26945e404c6fdfdddad5eadbaa371.zip
implemented freeCnf() module interface & fixed some mem leaks
The interface was actually not present in older versions, even though some modules already used it. The implementation was now done, and not in 6.3/6.4 because the resulting memory leak was ultra-slim and the new interface handling has some potential to seriously break things. Not the kind of thing you want to add in late beta state, if avoidable.
Diffstat (limited to 'plugins/imuxsock')
-rw-r--r--plugins/imuxsock/imuxsock.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/plugins/imuxsock/imuxsock.c b/plugins/imuxsock/imuxsock.c
index 19028470..eeb18fd2 100644
--- a/plugins/imuxsock/imuxsock.c
+++ b/plugins/imuxsock/imuxsock.c
@@ -1085,8 +1085,16 @@ ENDactivateCnf
BEGINfreeCnf
+ instanceConf_t *inst, *del;
CODESTARTfreeCnf
free(pModConf->pLogSockName);
+ for(inst = pModConf->root ; inst != NULL ; ) {
+ free(inst->sockName);
+ free(inst->pLogHostName);
+ del = inst;
+ inst = inst->next;
+ free(del);
+ }
ENDfreeCnf