summaryrefslogtreecommitdiff
path: root/source3/nsswitch
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2001-12-20 18:37:43 +0000
committerJeremy Allison <jra@samba.org>2001-12-20 18:37:43 +0000
commit6ac6af60cb1898619e383c362d8338b2de3d4e28 (patch)
tree7f2c2d43e9022faa78558e7252102e673a846c49 /source3/nsswitch
parentf7e4e37c63044c378a1ea624304b331c9c443fc9 (diff)
downloadsamba-6ac6af60cb1898619e383c362d8338b2de3d4e28.tar.gz
samba-6ac6af60cb1898619e383c362d8338b2de3d4e28.tar.bz2
samba-6ac6af60cb1898619e383c362d8338b2de3d4e28.zip
Setup global_myworkgroup. Needed for secrets fetch code.
Jeremy. (This used to be commit 057e91c1c3833516d03b492f3ebe489d8216a0ba)
Diffstat (limited to 'source3/nsswitch')
-rw-r--r--source3/nsswitch/winbindd.c19
1 files changed, 11 insertions, 8 deletions
diff --git a/source3/nsswitch/winbindd.c b/source3/nsswitch/winbindd.c
index 0db16b6874..c10cd9e2ca 100644
--- a/source3/nsswitch/winbindd.c
+++ b/source3/nsswitch/winbindd.c
@@ -724,6 +724,7 @@ struct winbindd_state server_state; /* Server state information */
int main(int argc, char **argv)
{
extern pstring global_myname;
+ extern fstring global_myworkgroup;
int accept_sock;
BOOL interactive = False;
int opt, new_debuglevel = -1;
@@ -780,6 +781,15 @@ int main(int argc, char **argv)
setup_logging("winbindd", interactive);
reopen_logs();
+ DEBUG(1, ("winbindd version %s started.\n", VERSION ) );
+ DEBUGADD( 1, ( "Copyright The Samba Team 2000-2001\n" ) );
+
+ if (!reload_services_file(False)) {
+ DEBUG(0, ("error opening config file\n"));
+ exit(1);
+ }
+
+ /* Setup names. */
if (!*global_myname) {
char *p;
@@ -789,14 +799,7 @@ int main(int argc, char **argv)
*p = 0;
}
-
- DEBUG(1, ("winbindd version %s started.\n", VERSION ) );
- DEBUGADD( 1, ( "Copyright The Samba Team 2000-2001\n" ) );
-
- if (!reload_services_file(False)) {
- DEBUG(0, ("error opening config file\n"));
- exit(1);
- }
+ fstrcpy(global_myworkgroup, lp_workgroup());
if (new_debuglevel != -1)
DEBUGLEVEL = new_debuglevel;