mirror of
https://git.openldap.org/openldap/openldap.git
synced 2026-01-06 23:19:59 -05:00
yet another problem in pr limits
This commit is contained in:
parent
a2a2ccf848
commit
249a214ca6
1 changed files with 9 additions and 9 deletions
|
|
@ -985,7 +985,7 @@ limits_check( Operation *op, SlapReply *rs )
|
|||
pr_total = op->ors_limit->lms_s_pr_total;
|
||||
}
|
||||
|
||||
if ( op->ors_limit->lms_s_pr_total == -1 ) {
|
||||
if ( pr_total == -1 ) {
|
||||
slimit = -1;
|
||||
|
||||
} else if ( pr_total > 0 && ( op->ors_slimit == -1 || op->ors_slimit > pr_total ) ) {
|
||||
|
|
@ -1047,19 +1047,19 @@ limits_check( Operation *op, SlapReply *rs )
|
|||
if ( op->ors_slimit <= 0 ) {
|
||||
op->ors_slimit = slimit;
|
||||
|
||||
} else if ( op->ors_slimit - op->o_pagedresults_state.ps_count > slimit ) {
|
||||
rs->sr_err = LDAP_ADMINLIMIT_EXCEEDED;
|
||||
send_ldap_result( op, rs );
|
||||
rs->sr_err = LDAP_SUCCESS;
|
||||
return -1;
|
||||
|
||||
} else {
|
||||
} else if ( slimit > 0 ) {
|
||||
if ( op->ors_slimit - op->o_pagedresults_state.ps_count > slimit ) {
|
||||
rs->sr_err = LDAP_ADMINLIMIT_EXCEEDED;
|
||||
send_ldap_result( op, rs );
|
||||
rs->sr_err = LDAP_SUCCESS;
|
||||
return -1;
|
||||
}
|
||||
op->ors_slimit = slimit;
|
||||
}
|
||||
|
||||
} else {
|
||||
/* use the standard hard/soft limit if any */
|
||||
op->ors_slimit = op->ors_limit->lms_s_hard;
|
||||
op->ors_slimit = pr_total;
|
||||
}
|
||||
|
||||
/* no limit requested: use soft, whatever it is */
|
||||
|
|
|
|||
Loading…
Reference in a new issue