summaryrefslogtreecommitdiff
path: root/source3/nsswitch
diff options
context:
space:
mode:
Diffstat (limited to 'source3/nsswitch')
-rw-r--r--source3/nsswitch/idmap_ldap.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/source3/nsswitch/idmap_ldap.c b/source3/nsswitch/idmap_ldap.c
index 7fdf16beaa..e5dd658fe3 100644
--- a/source3/nsswitch/idmap_ldap.c
+++ b/source3/nsswitch/idmap_ldap.c
@@ -965,7 +965,7 @@ again:
}
if ( ! entry) {
DEBUG(2, ("ERROR: Unable to fetch ldap entries from results\n"));
- continue;
+ break;
}
/* first check if the SID is present */
@@ -1180,6 +1180,10 @@ again:
} else { /* following ones */
entry = ldap_next_entry(ctx->smbldap_state->ldap_struct, entry);
}
+ if ( ! entry) {
+ DEBUG(2, ("ERROR: Unable to fetch ldap entries from results\n"));
+ break;
+ }
/* first check if the SID is present */
sidstr = smbldap_talloc_single_attribute(