mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-21 03:10:25 +08:00
Fix handling of non-critical controls for backends which
support no controls.
This commit is contained in:
parent
5aa29206cd
commit
bbbf2f4ca7
@ -125,13 +125,15 @@ ldap_charray_inlist(
|
||||
{
|
||||
int i;
|
||||
|
||||
for ( i = 0; a[i] != NULL; i++ ) {
|
||||
if( a == NULL ) return 0;
|
||||
|
||||
for ( i=0; a[i] != NULL; i++ ) {
|
||||
if ( strcasecmp( s, a[i] ) == 0 ) {
|
||||
return( 1 );
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
||||
return( 0 );
|
||||
return 0;
|
||||
}
|
||||
|
||||
char **
|
||||
|
@ -736,16 +736,9 @@ backend_check_controls(
|
||||
Operation *op,
|
||||
const char **text )
|
||||
{
|
||||
LDAPControl **ctrls;
|
||||
ctrls = op->o_ctrls;
|
||||
if( ctrls == NULL ) {
|
||||
return LDAP_SUCCESS;
|
||||
}
|
||||
LDAPControl **ctrls = op->o_ctrls;
|
||||
|
||||
if ( be->be_controls == NULL ) {
|
||||
*text = "control unavailable in context";
|
||||
return LDAP_UNAVAILABLE_CRITICAL_EXTENSION;
|
||||
}
|
||||
if( ctrls == NULL ) return LDAP_SUCCESS;
|
||||
|
||||
for( ; *ctrls != NULL ; ctrls++ ) {
|
||||
if( (*ctrls)->ldctl_iscritical &&
|
||||
|
Loading…
Reference in New Issue
Block a user