From: Howard Chu Date: Mon, 7 Apr 2003 11:40:23 +0000 (+0000) Subject: Cleanup previous X-Git-Tag: AUTOCONF_2_57~19 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=c4ab31ddc9258e75525f3aee01ceedcd00ec8e90;p=openldap Cleanup previous --- diff --git a/servers/slapd/back-ldap/search.c b/servers/slapd/back-ldap/search.c index d50f82ed80..fe2755c67a 100644 --- a/servers/slapd/back-ldap/search.c +++ b/servers/slapd/back-ldap/search.c @@ -533,24 +533,20 @@ ldap_build_entry( next_attr:; - if ( normalize ) { - if ( last && attr->a_desc->ad_type->sat_equality && - attr->a_desc->ad_type->sat_equality->smr_normalize ) { - int i; - - attr->a_nvals = ch_malloc((last+1)*sizeof(struct berval)); - for (i=0; ia_desc->ad_type->sat_equality->smr_normalize( - SLAP_MR_VALUE_OF_ATTRIBUTE_SYNTAX, - attr->a_desc->ad_type->sat_syntax, - attr->a_desc->ad_type->sat_equality, - &attr->a_vals[i], &attr->a_nvals[i] ); - } - attr->a_nvals[i].bv_val = NULL; - attr->a_nvals[i].bv_len = 0; - } else { - attr->a_nvals = attr->a_vals; + if ( normalize && last && attr->a_desc->ad_type->sat_equality && + attr->a_desc->ad_type->sat_equality->smr_normalize ) { + int i; + + attr->a_nvals = ch_malloc((last+1)*sizeof(struct berval)); + for (i=0; ia_desc->ad_type->sat_equality->smr_normalize( + SLAP_MR_VALUE_OF_ATTRIBUTE_SYNTAX, + attr->a_desc->ad_type->sat_syntax, + attr->a_desc->ad_type->sat_equality, + &attr->a_vals[i], &attr->a_nvals[i] ); } + attr->a_nvals[i].bv_val = NULL; + attr->a_nvals[i].bv_len = 0; } else { attr->a_nvals = attr->a_vals; }