From: Kurt Zeilenga Date: Thu, 30 Dec 2004 19:15:52 +0000 (+0000) Subject: Cleanup X-Git-Tag: OPENLDAP_REL_ENG_2_3_0ALPHA~7^2 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=951159447b741460e827e503e0b1802b3b774f7e;p=openldap Cleanup --- diff --git a/servers/slapd/attr.c b/servers/slapd/attr.c index 0de26e84e5..7dce6c6dd0 100644 --- a/servers/slapd/attr.c +++ b/servers/slapd/attr.c @@ -43,8 +43,9 @@ void attr_free( Attribute *a ) { - if ( a->a_nvals && a->a_nvals != a->a_vals ) + if ( a->a_nvals && a->a_nvals != a->a_vals ) { ber_bvarray_free( a->a_nvals ); + } ber_bvarray_free( a->a_vals ); free( a ); } diff --git a/servers/slapd/controls.c b/servers/slapd/controls.c index 76e470efe6..60db9aa411 100644 --- a/servers/slapd/controls.c +++ b/servers/slapd/controls.c @@ -1040,7 +1040,9 @@ static int parsePreRead ( an[i].an_oc_exclude = 0; rc = slap_bv2ad( &an[i].an_name, &an[i].an_desc, &dummy ); if ( rc != LDAP_SUCCESS && ctrl->ldctl_iscritical ) { - rs->sr_text = dummy ? dummy : "postread control: unknown attributeType"; + rs->sr_text = dummy + ? dummy + : "postread control: unknown attributeType"; return rc; } } @@ -1096,7 +1098,9 @@ static int parsePostRead ( an[i].an_oc_exclude = 0; rc = slap_bv2ad( &an[i].an_name, &an[i].an_desc, &dummy ); if ( rc != LDAP_SUCCESS && ctrl->ldctl_iscritical ) { - rs->sr_text = dummy ? dummy : "postread control: unknown attributeType"; + rs->sr_text = dummy + ? dummy + : "postread control: unknown attributeType"; return rc; } } diff --git a/servers/slapd/search.c b/servers/slapd/search.c index dd91c87a1a..ce7cbef7cd 100644 --- a/servers/slapd/search.c +++ b/servers/slapd/search.c @@ -164,7 +164,8 @@ do_search( op->ors_attrs[i].an_desc = NULL; op->ors_attrs[i].an_oc = NULL; op->ors_attrs[i].an_oc_exclude = 0; - slap_bv2ad(&op->ors_attrs[i].an_name, &op->ors_attrs[i].an_desc, &dummy); + slap_bv2ad(&op->ors_attrs[i].an_name, + &op->ors_attrs[i].an_desc, &dummy); } if( get_ctrls( op, rs, 1 ) != LDAP_SUCCESS ) {