Skip to contentSkip to conversation

multipath-tools: multipathd: Fix memory leak on load_config().

PATCH New Gris Ge 1 participant 1 message Jan 22, 2017 Device mapper

lore
Share & tools
lore

Gris Ge

author
#0 lore raw

PATCH 1/1 multipath-tools: multipathd: Fix memory leak on load_config().

* Just free_config() before exit.

---
 multipathd/main.c | 2 ++
 1 file changed, 2 insertions(+)
multipathd/main.c +2 -0
index 1e64afc..2f5042e 100644
@@ -2633,6 +2633,7 @@ main (int argc, char *argv[])
 				conf->verbosity = verbosity;
 			uxsock_timeout = conf->uxsock_timeout;
 			uxclnt(optarg, uxsock_timeout + 100);
+			free_config(conf);
 			exit(0);
 		case 'B':
 			bindings_read_only = 1;
@@ -2667,6 +2668,7 @@ main (int argc, char *argv[])
 		}
 		c += snprintf(c, s + CMDSIZE - c, "\n");
 		uxclnt(s, uxsock_timeout + 100);
+		free_config(conf);
 		exit(0);
 	}
 
Signature · 1 line
1.8.3.1