From: Matthias Dieter Wallnöfer Date: Sat, 13 Feb 2010 18:41:43 +0000 (+0100) Subject: s4:loadparm.c - the logfile parameter value needs to be duplicated X-Git-Tag: samba-3.6.0pre1~5327 X-Git-Url: http://git.samba.org/samba.git/?p=ira%2Fwip.git;a=commitdiff_plain;h=195bda569e541a49ab3406deca8c8b864ec327d4 s4:loadparm.c - the logfile parameter value needs to be duplicated Otherwise the "logfile" pointer tracks all changes of "pszParmValue" which content is only temporal. This was the cause of bug #6212. --- diff --git a/source4/param/loadparm.c b/source4/param/loadparm.c index cb23ceab02e..0841f7dad44 100644 --- a/source4/param/loadparm.c +++ b/source4/param/loadparm.c @@ -1542,7 +1542,7 @@ static bool handle_debuglevel(struct loadparm_context *lp_ctx, static bool handle_logfile(struct loadparm_context *lp_ctx, const char *pszParmValue, char **ptr) { - logfile = pszParmValue; + logfile = strdup(pszParmValue); return true; }