diff options
author | Stefan Metzmacher <metze@samba.org> | 2009-10-23 15:12:01 +0200 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2009-10-24 11:59:15 +0200 |
commit | 4ab83fb1b7d2929c6ae454f3f073d4baf3510ca3 (patch) | |
tree | bda714f26e50354b0a3e23b38f72c384b5389e8a | |
parent | 69e96f08f1def1c28abe928ccbb0717566e49c8c (diff) | |
download | samba-4ab83fb1b7d2929c6ae454f3f073d4baf3510ca3.tar.gz samba-4ab83fb1b7d2929c6ae454f3f073d4baf3510ca3.tar.bz2 samba-4ab83fb1b7d2929c6ae454f3f073d4baf3510ca3.zip |
s4:loadparm: don't leak the names of all shares in each lp_service() call
metze
-rw-r--r-- | source4/param/loadparm.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/source4/param/loadparm.c b/source4/param/loadparm.c index 882de1330e..669e0d7d22 100644 --- a/source4/param/loadparm.c +++ b/source4/param/loadparm.c @@ -2609,8 +2609,11 @@ struct loadparm_service *lp_service(struct loadparm_context *lp_ctx, serviceName = standard_sub_basic( lp_ctx->services[iService], lp_ctx->services[iService]->szService); - if (strequal(serviceName, service_name)) + if (strequal(serviceName, service_name)) { + talloc_free(serviceName); return lp_ctx->services[iService]; + } + talloc_free(serviceName); } } |