Skip to content
This repository has been archived by the owner on Nov 25, 2020. It is now read-only.

Commit

Permalink
Test variable as resource before exec ldap_control_paged_result_response
Browse files Browse the repository at this point in the history
  • Loading branch information
c12simple committed Nov 21, 2014
1 parent 91f76f5 commit f8d1fd0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion core/src/plugins/auth.ldap/class.ldapAuthDriver.php
Expand Up @@ -364,7 +364,8 @@ public function getUserEntries($login = null, $countOnly = false, $offset = -1,
}
if ($isSupportPagedResult)
foreach ($ret as $element) {
ldap_control_paged_result_response($this->ldapconn, $element, $cookie);
if(is_resource($element))
ldap_control_paged_result_response($this->ldapconn, $element, $cookie);
}
} while (($cookie !== null && $cookie != '') && ($isSupportPagedResult) && (!$gotAllEntries));

Expand Down

0 comments on commit f8d1fd0

Please sign in to comment.