ITS#4805 plug remaining leak

This commit is contained in:
Howard Chu 2007-01-25 07:10:34 +00:00
parent 009e911a9d
commit 5a263ba88f

View File

@ -1412,12 +1412,6 @@ syncrepl_message_to_entry(
return rc;
}
dnPrettyNormal( NULL, &bdn, &dn, &ndn, op->o_tmpmemctx );
ber_dupbv( &op->o_req_dn, &dn );
ber_dupbv( &op->o_req_ndn, &ndn );
slap_sl_free( ndn.bv_val, op->o_tmpmemctx );
slap_sl_free( dn.bv_val, op->o_tmpmemctx );
if ( syncstate == LDAP_SYNC_PRESENT || syncstate == LDAP_SYNC_DELETE ) {
/* NOTE: this could be done even before decoding the DN,
* although encoding errors wouldn't be detected */
@ -1430,6 +1424,12 @@ syncrepl_message_to_entry(
goto done;
}
dnPrettyNormal( NULL, &bdn, &dn, &ndn, op->o_tmpmemctx );
ber_dupbv( &op->o_req_dn, &dn );
ber_dupbv( &op->o_req_ndn, &ndn );
slap_sl_free( ndn.bv_val, op->o_tmpmemctx );
slap_sl_free( dn.bv_val, op->o_tmpmemctx );
e = entry_alloc();
e->e_name = op->o_req_dn;
e->e_nname = op->o_req_ndn;