summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRusty Russell <rusty@rustcorp.com.au>2012-07-18 05:09:31 +0930
committerRusty Russell <rusty@rustcorp.com.au>2012-07-18 05:09:31 +0930
commitc809eec53fb1d2a36909e4934dff349f91e3359e (patch)
tree338b64b8ea82010a6edce0e52f0f95f6d3a97888
parentaa2e02e6846c4fa8199ebafbe6b9e050df8af16b (diff)
downloadsamba-c809eec53fb1d2a36909e4934dff349f91e3359e.tar.gz
samba-c809eec53fb1d2a36909e4934dff349f91e3359e.tar.bz2
samba-c809eec53fb1d2a36909e4934dff349f91e3359e.zip
source3/utils/net_conf.c: fix stackframe leak
net_conf_wrap_function() doesn't free its stackframe. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
-rw-r--r--source3/utils/net_conf.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source3/utils/net_conf.c b/source3/utils/net_conf.c
index b257ce1786..60588c0eed 100644
--- a/source3/utils/net_conf.c
+++ b/source3/utils/net_conf.c
@@ -1131,6 +1131,7 @@ static int net_conf_wrap_function(struct net_context *c,
err = smbconf_init(mem_ctx, &conf_ctx, "registry:");
if (!SBC_ERROR_IS_OK(err)) {
+ talloc_free(mem_ctx);
return -1;
}
@@ -1138,6 +1139,7 @@ static int net_conf_wrap_function(struct net_context *c,
smbconf_shutdown(conf_ctx);
+ talloc_free(mem_ctx);
return ret;
}