diff --git a/servers/slapd/attr.c b/servers/slapd/attr.c index f4aa43308d64a9069d7da4523826c7349aa40c01..9239e161f812e6c378608858e8c8f7ec2edcb634 100644 --- a/servers/slapd/attr.c +++ b/servers/slapd/attr.c @@ -109,9 +109,9 @@ Attribute *attrs_dup( Attribute *a ) int attr_merge( - Entry *e, + Entry *e, AttributeDescription *desc, - struct berval **vals ) + struct berval **vals ) { Attribute **a; diff --git a/servers/slapd/back-ldbm/modify.c b/servers/slapd/back-ldbm/modify.c index 86a1bbd41d162dfab88d7353853389c311d40007..bf5ebd44095272d1e4d8d531ab0a130d5e186b6c 100644 --- a/servers/slapd/back-ldbm/modify.c +++ b/servers/slapd/back-ldbm/modify.c @@ -275,9 +275,9 @@ add_values( /* check if the values we're adding already exist */ if ( a != NULL ) { - /* do allow add of additional attribute if - no equality rule exists */ - if( mr == NULL ) { + if( mr == NULL || !mr->smr_match ) { + /* do not allow add of additional attribute + if no equality rule exists */ return LDAP_INAPPROPRIATE_MATCHING; } @@ -339,9 +339,9 @@ delete_values( LDAP_NO_SUCH_ATTRIBUTE : LDAP_SUCCESS ); } - /* disallow specific attributes from being deleted if - no equality rule */ if( mr == NULL || !mr->smr_match ) { + /* disallow specific attributes from being deleted if + no equality rule */ return LDAP_INAPPROPRIATE_MATCHING; }