Merge pull request #12100 from owncloud/fix-infinite-loop

Fix infinite loop if count and limit is 0
This commit is contained in:
Morris Jobke 2014-11-11 13:29:39 +01:00
commit 0de9368ab2
1 changed files with 1 additions and 1 deletions

View File

@ -928,7 +928,7 @@ class Access extends LDAPUtility implements user\IUserTools {
foreach($searchResults as $res) {
$count = intval($this->ldap->countEntries($cr, $res));
$counter += $count;
if($count === $limit) {
if($count > 0 && $count === $limit) {
$hasHitLimit = true;
}
}