diff options
author | Jeremy Allison <jra@samba.org> | 2007-01-17 18:25:35 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2007-01-17 18:25:35 +0000 |
commit | 37b015b36bcf5da6ac985105b06ffcbe819a01de (patch) | |
tree | 5ac72a0d0079f43ad1fbd25b8dd4f8824f716ab8 /source/utils/net_ads.c | |
parent | e8cf89ac47e458add8d9febe8b601d544c367bb7 (diff) | |
download | samba-37b015b36bcf5da6ac985105b06ffcbe819a01de.tar.gz samba-37b015b36bcf5da6ac985105b06ffcbe819a01de.tar.xz samba-37b015b36bcf5da6ac985105b06ffcbe819a01de.zip |
r20857: Silence gives assent :-). Checking in the fix for
site support in a network where many DC's are down.
I heard via Volker there is still a bug w.r.t the
wrong site being chosen with trusted domains but
we'll have to layer that fix on top of this.
Gd - complain if this doesn't work for you.
Jeremy.
Diffstat (limited to 'source/utils/net_ads.c')
-rw-r--r-- | source/utils/net_ads.c | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/source/utils/net_ads.c b/source/utils/net_ads.c index 8c35f201ad7..bd679839546 100644 --- a/source/utils/net_ads.c +++ b/source/utils/net_ads.c @@ -218,8 +218,6 @@ static ADS_STATUS ads_startup_int(BOOL only_own_domain, uint32 auth_flags, ADS_S char *cp; const char *realm = NULL; BOOL tried_closest_dc = False; - BOOL closest_dc = False; - BOOL site_matches = False; /* lp_realm() should be handled by a command line param, However, the join requires that realm be set in smb.conf @@ -290,7 +288,7 @@ retry: return status; } - if (!need_password && !second_time) { + if (!need_password && !second_time && !(auth_flags & ADS_AUTH_NO_BIND)) { need_password = True; second_time = True; goto retry; @@ -304,17 +302,11 @@ retry: * This is done by reconnecting to ADS because only the first call to * ads_connect will give us our own sitename */ - closest_dc = (ads->config.flags & ADS_CLOSEST); - site_matches = ads_sitename_match(ads); - - DEBUG(10,("ads_startup_int: DC %s closest DC\n", closest_dc ? "is":"is *NOT*")); - DEBUG(10,("ads_startup_int: sitenames %s match\n", site_matches ? "do":"do *NOT*")); - if ((only_own_domain || !opt_host) && !tried_closest_dc) { tried_closest_dc = True; /* avoid loop */ - if (!ads_closest_dc(ads)) { + if (!ads->config.tried_closest_dc) { namecache_delete(ads->server.realm, 0x1C); namecache_delete(ads->server.workgroup, 0x1C); |