summaryrefslogtreecommitdiffstats
path: root/source
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2008-10-27 19:38:15 +0100
committerStefan Metzmacher <metze@samba.org>2008-12-13 18:43:46 +0100
commit60c0166fd492bb6cff41811973c8da026c5109d7 (patch)
treefe270ebd257b70ed978c967ba3f358fbb2916c3a /source
parentf771eee7878fd4d5e670000256032ed56f537d8e (diff)
downloadsamba-60c0166fd492bb6cff41811973c8da026c5109d7.tar.gz
samba-60c0166fd492bb6cff41811973c8da026c5109d7.tar.xz
samba-60c0166fd492bb6cff41811973c8da026c5109d7.zip
s3:libads/ldap.c: if the client belongs to no site at all any dc is the closest
metze Signed-off-by: Stefan Metzmacher <metze@samba.org> Signed-off-by: Günther Deschner <gd@samba.org> (cherry picked from commit f86ef9b53a903485deba94febf90dd4e657cc02b) (cherry picked from commit a8040d59659e58c5cb92c1107a7ff012eff12729) (cherry picked from commit 7baceea20252dec6b64e86ec8b5a73b62b373758)
Diffstat (limited to 'source')
-rw-r--r--source/libads/ldap.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/source/libads/ldap.c b/source/libads/ldap.c
index 9045552c81e..a462f463c77 100644
--- a/source/libads/ldap.c
+++ b/source/libads/ldap.c
@@ -162,6 +162,11 @@ bool ads_closest_dc(ADS_STRUCT *ads)
return True;
}
+ if (ads->config.client_site_name == NULL) {
+ DEBUG(10,("ads_closest_dc: client belongs to no site\n"));
+ return True;
+ }
+
DEBUG(10,("ads_closest_dc: %s is not the closest DC\n",
ads->config.ldap_server_name));