Modify replace_values not to merge in new values when no value is

was provided.
This commit is contained in:
Kurt Zeilenga 1999-08-11 19:05:40 +00:00
parent 740f1b422e
commit 49207930cf
2 changed files with 6 additions and 2 deletions

View File

@ -314,7 +314,9 @@ bdb2i_replace_values(
{
(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 );
}

View File

@ -346,7 +346,9 @@ replace_values(
{
(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 );
}