summaryrefslogtreecommitdiffstats
path: root/syslogd.c
diff options
context:
space:
mode:
Diffstat (limited to 'syslogd.c')
-rw-r--r--syslogd.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/syslogd.c b/syslogd.c
index 904bdbd3..cd8476d4 100644
--- a/syslogd.c
+++ b/syslogd.c
@@ -1056,10 +1056,11 @@ static rsRetVal shouldProcessThisMessage(selector_t *f, msg_t *pMsg, int *bProce
finalize_it:
/* destruct in any case, not just on error, but it makes error handling much easier */
- if(pVM != NULL) {
- var.Destruct(&pResult);
+ if(pVM != NULL)
vm.Destruct(&pVM);
- }
+
+ if(pResult != NULL)
+ var.Destruct(&pResult);
*bProcessMsg = bRet;
RETiRet;