mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-15 03:01:09 +08:00
Modify replace_values not to merge in new values when no value is
was provided.
This commit is contained in:
parent
740f1b422e
commit
49207930cf
@ -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 );
|
||||
}
|
||||
|
||||
|
@ -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 );
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user