#endif /* !NEW_LOGGING */
lc_curr.conn = conn;
+ lc_curr.local_dn = conn->c_ndn;
ldap_pvt_thread_mutex_lock( &li->conn_mutex );
lc = avl_delete( &li->conntree, (caddr_t)&lc_curr, ldap_back_conn_cmp );
* and calling ldap_unbind on a corrupted header results
* in a segmentation fault
*/
- ldap_unbind(lc->ld);
- if ( lc->bound_dn.bv_val ) {
- ch_free( lc->bound_dn.bv_val );
- }
- if ( lc->cred.bv_val ) {
- ch_free( lc->cred.bv_val );
- }
- ch_free( lc );
+ ldap_back_conn_free( lc );
}
/* no response to unbind */