mirror of
https://git.openldap.org/openldap/openldap.git
synced 2026-01-25 16:22:53 -05:00
ITS#9991 send_ldap_ber: make sure we're only closing our own connection
This commit is contained in:
parent
868309c90d
commit
801297cb77
1 changed files with 3 additions and 1 deletions
|
|
@ -398,7 +398,9 @@ fail:
|
|||
conn->c_writing = 0;
|
||||
ldap_pvt_thread_mutex_unlock( &conn->c_write1_mutex );
|
||||
ldap_pvt_thread_mutex_lock( &conn->c_mutex );
|
||||
connection_closing( conn, close_reason );
|
||||
/* conn may have been reused by the time we get the mutex */
|
||||
if ( op->o_connid == conn->c_connid )
|
||||
connection_closing( conn, close_reason );
|
||||
ldap_pvt_thread_mutex_unlock( &conn->c_mutex );
|
||||
return -1;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue