From f741f656737f4ec46cd318e986b6bf412ed309d2 Mon Sep 17 00:00:00 2001 From: Martin Pool Date: Mon, 19 Nov 2001 02:49:53 +0000 Subject: Store some path names in global variables initialized to configure default, rather than in preprocessor macros. (This used to be commit 79ec88f0da40faebe1e587f1b3e87b5f2b184f58) --- source3/nsswitch/winbindd.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'source3/nsswitch/winbindd.c') diff --git a/source3/nsswitch/winbindd.c b/source3/nsswitch/winbindd.c index 30e5f41b9e..56ed17464b 100644 --- a/source3/nsswitch/winbindd.c +++ b/source3/nsswitch/winbindd.c @@ -23,8 +23,6 @@ #include "winbindd.h" -pstring servicesf = CONFIGFILE; - /* List of all connected clients */ struct winbindd_cli_state *client_list; @@ -40,14 +38,14 @@ static BOOL reload_services_file(BOOL test) pstring fname; pstrcpy(fname,lp_configfile()); - if (file_exist(fname,NULL) && !strcsequal(fname,servicesf)) { - pstrcpy(servicesf,fname); + if (file_exist(fname,NULL) && !strcsequal(fname,dyn_CONFIGFILE)) { + pstrcpy(dyn_CONFIGFILE,fname); test = False; } } reopen_logs(); - ret = lp_load(servicesf,False,False,True); + ret = lp_load(dyn_CONFIGFILE,False,False,True); reopen_logs(); load_interfaces(); @@ -713,7 +711,7 @@ int main(int argc, char **argv) /* Load a different smb.conf file */ case 's': - pstrcpy(servicesf,optarg); + pstrcpy(dyn_CONFIGFILE,optarg); break; default: @@ -722,7 +720,7 @@ int main(int argc, char **argv) } } - snprintf(debugf, sizeof(debugf), "%s/log.winbindd", LOGFILEBASE); + snprintf(debugf, sizeof(debugf), "%s/log.winbindd", dyn_LOGFILEBASE); setup_logging("winbindd", interactive); reopen_logs(); -- cgit