From 2001b83faa9f0438adda40ffe12fea4a3dc6a733 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Wed, 13 Mar 2002 06:43:52 +0000 Subject: detect SIZELIMIT_EXCEEDED in ldap queries and truncate the problem is, how the heck do we properly handle these? Jerry? It seems that the Win2000 ADS server only returns a max of 1000 records! (This used to be commit 93389647203395da0e894c2e57348081e755884a) --- source3/libads/ldap.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'source3/libads') diff --git a/source3/libads/ldap.c b/source3/libads/ldap.c index aa6e7c0036..e53f6d87db 100644 --- a/source3/libads/ldap.c +++ b/source3/libads/ldap.c @@ -84,6 +84,10 @@ ADS_STATUS ads_do_search(ADS_STRUCT *ads, const char *bind_path, int scope, bind_path, scope, exp, (char **) attrs, 0, NULL, NULL, &timeout, LDAP_NO_LIMIT, (LDAPMessage **)res); + if (rc == LDAP_SIZELIMIT_EXCEEDED) { + DEBUG(3,("Warning! sizelimit exceeded in ldap. Truncating.\n")); + rc = 0; + } return ADS_ERROR(rc); } /* -- cgit