winbind: set logfile after reloading config
authorRalph Boehme <slow@samba.org>
Wed, 20 Jan 2021 11:27:23 +0000 (12:27 +0100)
committerJeremy Allison <jra@samba.org>
Thu, 21 Jan 2021 21:48:30 +0000 (21:48 +0000)
lp_load_global() will overwrite whatever we've set with lp_set_logfile().

BUG: https://bugzilla.samba.org/show_bug.cgi?id=14602

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/winbindd/winbindd.c

index 9ae7912b9ff9614b8f71797ee84c659739264d6f..3049faa32373ee7119fedc0b18ad69f9d609b729 100644 (file)
@@ -118,15 +118,15 @@ bool winbindd_reload_services_file(const char *lfile)
                TALLOC_FREE(fname);
        }
 
+       reopen_logs();
+       ret = lp_load_global(get_dyn_CONFIGFILE());
+
        /* if this is a child, restore the logfile to the special
           name - <domain>, idmap, etc. */
        if (lfile && *lfile) {
                lp_set_logfile(lfile);
        }
 
-       reopen_logs();
-       ret = lp_load_global(get_dyn_CONFIGFILE());
-
        reopen_logs();
        load_interfaces();
        winbindd_setup_max_fds();