diff options
author | Volker Lendecke <vl@samba.org> | 2010-03-28 14:13:48 +0200 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2010-03-28 15:25:16 +0200 |
commit | 0205633ed94a19d8723c3f2f252daf1b96729375 (patch) | |
tree | 1b5d1f3e99f6ea11ff9f60be9eefa767472df3cc | |
parent | 48f90be7b9560258054486dce6514476b669ebfb (diff) | |
download | samba-0205633ed94a19d8723c3f2f252daf1b96729375.tar.gz samba-0205633ed94a19d8723c3f2f252daf1b96729375.tar.bz2 samba-0205633ed94a19d8723c3f2f252daf1b96729375.zip |
s3: Use bitmap_talloc in loadparm
-rw-r--r-- | source3/param/loadparm.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c index c7497c4d04..b0f78f98a0 100644 --- a/source3/param/loadparm.c +++ b/source3/param/loadparm.c @@ -6091,7 +6091,7 @@ static void free_service(struct service *pservice) free_parameters(pservice); string_free(&pservice->szService); - bitmap_free(pservice->copymap); + TALLOC_FREE(pservice->copymap); free_param_opts(&pservice->param_opt); @@ -7572,10 +7572,11 @@ static bool handle_printing(int snum, const char *pszParmValue, char **ptr) static void init_copymap(struct service *pservice) { int i; - if (pservice->copymap) { - bitmap_free(pservice->copymap); - } - pservice->copymap = bitmap_allocate(NUMPARAMETERS); + + TALLOC_FREE(pservice->copymap); + + pservice->copymap = bitmap_talloc(talloc_autofree_context(), + NUMPARAMETERS); if (!pservice->copymap) DEBUG(0, ("Couldn't allocate copymap!! (size %d)\n", |