var count is assigned in the inner loop so it must be checked inside there to be properly used as part of the exit condition of the outer loop
This commit is contained in:
parent
43402c56dd
commit
bdc418d1f9
|
@ -786,6 +786,7 @@ class Access extends LDAPUtility {
|
||||||
$cr = $this->connection->getConnectionResource();
|
$cr = $this->connection->getConnectionResource();
|
||||||
|
|
||||||
do {
|
do {
|
||||||
|
$continue = false;
|
||||||
$search = $this->executeSearch($filter, $base, $attr,
|
$search = $this->executeSearch($filter, $base, $attr,
|
||||||
$limit, $offset);
|
$limit, $offset);
|
||||||
if($search === false) {
|
if($search === false) {
|
||||||
|
@ -798,12 +799,15 @@ class Access extends LDAPUtility {
|
||||||
if($count !== false) {
|
if($count !== false) {
|
||||||
$counter += $count;
|
$counter += $count;
|
||||||
}
|
}
|
||||||
|
if($count === $limit) {
|
||||||
|
$continue = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->processPagedSearchStatus($sr, $filter, $base, $count, $limit,
|
$this->processPagedSearchStatus($sr, $filter, $base, $count, $limit,
|
||||||
$offset, $pagedSearchOK, $skipHandling);
|
$offset, $pagedSearchOK, $skipHandling);
|
||||||
$offset += $limit;
|
$offset += $limit;
|
||||||
} while($count === $limit);
|
} while($continue);
|
||||||
|
|
||||||
return $counter;
|
return $counter;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue