Signed-off-by: awalker <awalker@ixsystems.com>
Reviewed-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Wed May 13 17:34:43 UTC 2020 on sn-devel-184
char *n2;
bool bRetval;
- filename = talloc_strdup(lp_ctx, filename);
+ if (lp_ctx->szConfigFile != NULL) {
+ talloc_free(discard_const_p(char, lp_ctx->szConfigFile));
+ lp_ctx->szConfigFile = NULL;
+ }
- lp_ctx->szConfigFile = filename;
+ lp_ctx->szConfigFile = talloc_strdup(lp_ctx, filename);
if (lp_ctx->s3_fns) {
return lp_ctx->s3_fns->load(filename);