{
(void) attr_delete( &e->e_attrs, mod->mod_type );
- if ( attr_merge( e, mod->mod_type, mod->mod_bvalues ) != 0 ) {
+ if ( mod->bvalues != NULL &&
+ attr_merge( e, mod->mod_type, mod->mod_bvalues ) != 0 )
+ {
return( LDAP_CONSTRAINT_VIOLATION );
}
{
(void) attr_delete( &e->e_attrs, mod->mod_type );
- if ( attr_merge( e, mod->mod_type, mod->mod_bvalues ) != 0 ) {
+ if ( mod->mod_bvalues != NULL &&
+ attr_merge( e, mod->mod_type, mod->mod_bvalues ) != 0 )
+ {
return( LDAP_CONSTRAINT_VIOLATION );
}