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
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;