From: Pierangelo Masarati Date: Mon, 27 Sep 2004 22:04:20 +0000 (+0000) Subject: fix ITS#3346 X-Git-Tag: OPENLDAP_REL_ENG_2_3_0ALPHA~493 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=b2cd66c0d874085b18d23d0c7ae0e6ae68949be5;p=openldap fix ITS#3346 --- diff --git a/servers/slapd/mods.c b/servers/slapd/mods.c index bda5738a47..00ae400788 100644 --- a/servers/slapd/mods.c +++ b/servers/slapd/mods.c @@ -219,9 +219,13 @@ modify_delete_values( return LDAP_NO_SUCH_ATTRIBUTE; } - for ( i = 0; mod->sm_values[i].bv_val != NULL; i++ ) { + for ( i = 0; !BER_BVISNULL( &mod->sm_values[i] ); i++ ) { int found = 0; - for ( j = 0; a->a_vals[j].bv_val != NULL; j++ ) { + for ( j = 0; !BER_BVISNULL( &a->a_vals[j] ); j++ ) { + /* skip already deleted values */ + if ( a->a_vals[j].bv_val == &dummy ) { + continue; + } if( mod->sm_nvalues ) { assert( a->a_nvals );