blob: d439a2607b059ca38f894948bf78c927f9dac9f8 [file] [log] [blame]
Patrick Williamsb48b7b42016-08-17 15:04:38 -05001From 3ef6ca8044260c77118edca6dead807a2edcb5ef Mon Sep 17 00:00:00 2001
2From: Balazs Scheidler <bazsi@balabit.hu>
3Date: Thu, 31 Oct 2013 13:20:12 +0100
4Subject: [PATCH] cfg: free global LogTemplateOptions
5
6Upstream-Status: Backport
7
8This fixes a potential memory leak when global template specific
9options were specified, such as local-time-zone(), send-time-zone() etc.
10
11Signed-off-by: Balazs Scheidler <bazsi@balabit.hu>
12---
13 lib/cfg.c | 1 +
14 1 file changed, 1 insertion(+)
15
16diff --git a/lib/cfg.c b/lib/cfg.c
17index 7f040b8..adeaaf8 100644
18--- a/lib/cfg.c
19+++ b/lib/cfg.c
20@@ -411,6 +411,7 @@ cfg_free(GlobalConfig *self)
21 g_free(self->proto_template_name);
22 log_template_unref(self->file_template);
23 log_template_unref(self->proto_template);
24+ log_template_options_destroy(&self->template_options);
25
26 if (self->bad_hostname_compiled)
27 regfree(&self->bad_hostname);
28--
291.8.4.1
30