From 265ffe01f2ddc241af968f3e41ceb6f4311464eb Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Wed, 22 Apr 2009 02:54:11 -0700 Subject: Fix bug #6279 - winbindd crash. Cope with LDAP libraries returning LDAP_SUCCESS but not returning a result. Jeremy --- source3/libads/ldap.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/source3/libads/ldap.c b/source3/libads/ldap.c index 9ffbd57e4a..74f9b94a12 100644 --- a/source3/libads/ldap.c +++ b/source3/libads/ldap.c @@ -118,6 +118,10 @@ static int ldap_search_with_timeout(LDAP *ld, if (gotalarm != 0) return LDAP_TIMELIMIT_EXCEEDED; + if (*res == NULL) { + return LDAP_TIMELIMIT_EXCEEDED; + } + return result; } -- cgit