diff options
author | Stefan Metzmacher <metze@samba.org> | 2008-04-15 10:57:16 +0200 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2008-04-18 15:00:20 +0200 |
commit | 913cd26b2b2afc30a4295ede31c7f5f4ea4a71bc (patch) | |
tree | 129892f211f22b4618dc4e41d8bc252eba6f4ce2 /source3 | |
parent | 94b603648fdb074eec1f208d423ed1349e3d3841 (diff) | |
download | samba-913cd26b2b2afc30a4295ede31c7f5f4ea4a71bc.tar.gz samba-913cd26b2b2afc30a4295ede31c7f5f4ea4a71bc.tar.bz2 samba-913cd26b2b2afc30a4295ede31c7f5f4ea4a71bc.zip |
winbindd: create the messaging conntext earlier
metze
(This used to be commit 2e1b9130635235efdbf49d0b92a43b342114246c)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/winbindd/winbindd.c | 24 |
1 files changed, 17 insertions, 7 deletions
diff --git a/source3/winbindd/winbindd.c b/source3/winbindd/winbindd.c index ff9bbf1c24..64674b8ace 100644 --- a/source3/winbindd/winbindd.c +++ b/source3/winbindd/winbindd.c @@ -1023,6 +1023,8 @@ int main(int argc, char **argv, char **envp) load_case_tables(); + db_tdb2_setup_messaging(NULL, false); + /* Initialise for running in non-root mode */ sec_init(); @@ -1102,7 +1104,19 @@ int main(int argc, char **argv, char **envp) DEBUG(0,("winbindd version %s started.\n", SAMBA_VERSION_STRING)); DEBUGADD(0,("%s\n", COPYRIGHT_STARTUP_MESSAGE)); - db_tdb2_setup_messaging(NULL, false); + if (!lp_load_initial_only(get_dyn_CONFIGFILE())) { + DEBUG(0, ("error opening config file\n")); + exit(1); + } + + /* Initialise messaging system */ + + if (winbind_messaging_context() == NULL) { + DEBUG(0, ("unable to initialize messaging system\n")); + exit(1); + } + + db_tdb2_setup_messaging(winbind_messaging_context(), true); if (!reload_services_file()) { DEBUG(0, ("error opening config file\n")); @@ -1175,10 +1189,8 @@ int main(int argc, char **argv, char **envp) TimeInit(); - /* Initialise messaging system */ - - if (winbind_messaging_context() == NULL) { - DEBUG(0, ("unable to initialize messaging system\n")); + if (!reinit_after_fork(winbind_messaging_context())) { + DEBUG(0,("reinit_after_fork() failed\n")); exit(1); } @@ -1219,8 +1231,6 @@ int main(int argc, char **argv, char **envp) MSG_WINBIND_DUMP_DOMAIN_LIST, winbind_msg_dump_domain_list); - db_tdb2_setup_messaging(winbind_messaging_context(), true); - netsamlogon_cache_init(); /* Non-critical */ /* clear the cached list of trusted domains */ |