mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-21 03:10:25 +08:00
Removed control old kludge code
This commit is contained in:
parent
4d5068630c
commit
1ff692274a
@ -859,17 +859,9 @@ backend_check_controls(
|
||||
assert( 0 );
|
||||
}
|
||||
|
||||
} else if (
|
||||
#ifdef SLAP_CONTROL_AVAILABILITY_KLUDGE
|
||||
/* KLUDGE: ldctl_iscritical munged by controls.c:get_ctrls()
|
||||
* to ensure this check is enabled/disabled appropriately.
|
||||
*/
|
||||
(*ctrls)->ldctl_iscritical &&
|
||||
#else
|
||||
!slap_global_control( op, (*ctrls)->ldctl_oid ) &&
|
||||
#endif
|
||||
} else if ( !slap_global_control( op, (*ctrls)->ldctl_oid ) &&
|
||||
!ldap_charray_inlist( op->o_bd->be_controls,
|
||||
(*ctrls)->ldctl_oid ) )
|
||||
(*ctrls)->ldctl_oid ) )
|
||||
{
|
||||
/* Per RFC 2251 (and LDAPBIS discussions), if the control
|
||||
* is recognized and appropriate for the operation (which
|
||||
|
@ -640,24 +640,6 @@ int get_ctrls(
|
||||
goto return_results;
|
||||
}
|
||||
|
||||
#ifdef SLAP_CONTROL_AVAILABILITY_KLUDGE
|
||||
/* backend_check_controls() kludge */
|
||||
if ( sc->sc_mask & SLAP_CTRL_GLOBAL ) {
|
||||
/* KLUDGE: disable backend_control() check */
|
||||
c->ldctl_iscritical = 0;
|
||||
|
||||
} else if ( tagmask == SLAP_CTRL_SEARCH &&
|
||||
sc->sc_mask & SLAP_CTRL_GLOBAL_SEARCH )
|
||||
{
|
||||
/* KLUDGE: disable backend_control() check */
|
||||
c->ldctl_iscritical = 0;
|
||||
|
||||
} else {
|
||||
/* KLUDGE: enable backend_control() check */
|
||||
c->ldctl_iscritical = 1;
|
||||
}
|
||||
#endif
|
||||
|
||||
} else if( c->ldctl_iscritical ) {
|
||||
/* unavailable CRITICAL control */
|
||||
rs->sr_err = LDAP_UNAVAILABLE_CRITICAL_EXTENSION;
|
||||
|
Loading…
Reference in New Issue
Block a user