From: Kurt Zeilenga Date: Sat, 3 Feb 2001 01:49:12 +0000 (+0000) Subject: Fix memory leak X-Git-Tag: LDBM_PRE_GIANT_RWLOCK~1515 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=12e9ed8e1297ea284895d62698561fab2a03fc17;p=openldap Fix memory leak --- diff --git a/libraries/libldap/getattr.c b/libraries/libldap/getattr.c index 5ffc1fa81e..4dbe3c3fb9 100644 --- a/libraries/libldap/getattr.c +++ b/libraries/libldap/getattr.c @@ -68,6 +68,7 @@ ldap_first_attribute( LDAP *ld, LDAPMessage *entry, BerElement **berout ) if ( ber_pvt_ber_remaining( ber ) == 0 ) { assert( len == 0 ); + ber_free( ber, 0 ); return NULL; } assert( len != 0 );