From: Pierangelo Masarati Date: Tue, 25 Oct 2005 14:50:05 +0000 (+0000) Subject: fix previous commit X-Git-Tag: OPENLDAP_REL_ENG_2_2_MP~197 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=cfa2eefe3c4d20c5a6a7b270acf22f61aaed28cb;p=openldap fix previous commit --- diff --git a/servers/slapd/back-meta/search.c b/servers/slapd/back-meta/search.c index 37fefb0dd7..7adabf379e 100644 --- a/servers/slapd/back-meta/search.c +++ b/servers/slapd/back-meta/search.c @@ -928,13 +928,10 @@ meta_send_entry( if ( BER_BVISNULL( &mapped ) || mapped.bv_val[0] == '\0' ) { continue; } - attr = ( Attribute * )ch_malloc( sizeof( Attribute ) ); + attr = ( Attribute * )ch_calloc( 1, sizeof( Attribute ) ); if ( attr == NULL ) { continue; } - attr->a_flags = 0; - attr->a_next = 0; - attr->a_desc = NULL; if ( slap_bv2ad( &mapped, &attr->a_desc, &text ) != LDAP_SUCCESS) { if ( slap_bv2undef_ad( &mapped, &attr->a_desc, &text, @@ -990,7 +987,6 @@ meta_send_entry( pretty = attr->a_desc->ad_type->sat_syntax->ssyn_pretty; if ( !validate && !pretty ) { - attr->a_nvals = NULL; attr_free( attr ); goto next_attr; }