summaryrefslogtreecommitdiffstats
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 11:42:36 +0100
commita8040d59659e58c5cb92c1107a7ff012eff12729 (patch)
treeffef9854bd86b6cd6576843a211a3958c41e820f
parent2f27ffc4a2ba745341a5961b8f04e62da3fb089a (diff)
downloadsamba-a8040d59659e58c5cb92c1107a7ff012eff12729.tar.gz
samba-a8040d59659e58c5cb92c1107a7ff012eff12729.tar.xz
samba-a8040d59659e58c5cb92c1107a7ff012eff12729.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)
-rw-r--r--source3/libads/ldap.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/source3/libads/ldap.c b/source3/libads/ldap.c
index 61e04d1e7c..c0bb9c7e2d 100644
--- a/source3/libads/ldap.c
+++ b/source3/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));