From edd94901e51be13377d874b2960222a1bb262b8c Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=A9mie=20Galarneau?= Date: Thu, 2 Jul 2015 18:55:17 -0400 Subject: [PATCH] Fix: Memory leak in setup of relayd_path MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jérémie Galarneau --- src/bin/lttng-relayd/health-relayd.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/bin/lttng-relayd/health-relayd.c b/src/bin/lttng-relayd/health-relayd.c index e3e48c919..d34a376c5 100644 --- a/src/bin/lttng-relayd/health-relayd.c +++ b/src/bin/lttng-relayd/health-relayd.c @@ -151,7 +151,7 @@ static int setup_health_path(void) { int is_root, ret = 0; - char *home_path = NULL, *rundir = NULL, *relayd_path; + char *home_path = NULL, *rundir = NULL, *relayd_path = NULL; ret = parse_health_env(); if (ret) { @@ -223,6 +223,7 @@ int setup_health_path(void) end: free(rundir); + free(relayd_path); return ret; } -- 2.34.1