summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2012-06-25 23:25:03 +0200
committerFelix Fietkau <nbd@openwrt.org>2012-06-25 23:25:03 +0200
commit4fe65b991edfb15a57da188698065b528e1e7e0e (patch)
treea8740c27c4ae0a0ea483a7edf5fc1dbb47bc390e
parent3688e3a3c27e71e4e20c47dc749a3fcb1fc9be20 (diff)
downloadunitd-4fe65b991edfb15a57da188698065b528e1e7e0e.tar
unitd-4fe65b991edfb15a57da188698065b528e1e7e0e.zip
fix a memleak
-rw-r--r--instance.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/instance.c b/instance.c
index 70380af..b84e7c8 100644
--- a/instance.c
+++ b/instance.c
@@ -222,6 +222,8 @@ instance_config_move(struct service_instance *in, struct service_instance *in_sr
in->command = in_src->command;
in->name = in_src->name;
in->node.avl.key = in_src->node.avl.key;
+
+ free(in->config);
in->config = in_src->config;
in_src->config = NULL;
}