mirror of
https://github.com/transmission/transmission
synced 2024-12-26 17:47:37 +00:00
Fix io_dtor for uTP sockets.
This commit is contained in:
parent
87d1f5ca34
commit
5ad27d82cf
1 changed files with 4 additions and 3 deletions
|
@ -544,13 +544,14 @@ io_dtor( void * vio )
|
|||
|
||||
dbgmsg( io, "in tr_peerIo destructor" );
|
||||
event_disable( io, EV_READ | EV_WRITE );
|
||||
event_free( io->event_read );
|
||||
event_free( io->event_write );
|
||||
tr_bandwidthDestruct( &io->bandwidth );
|
||||
evbuffer_free( io->outbuf );
|
||||
evbuffer_free( io->inbuf );
|
||||
if( io->socket >= 0 )
|
||||
if( io->socket >= 0 ) {
|
||||
event_free( io->event_read );
|
||||
event_free( io->event_write );
|
||||
tr_netClose( io->session, io->socket );
|
||||
}
|
||||
if( io->utp_socket != NULL )
|
||||
UTP_Close( io->utp_socket );
|
||||
tr_cryptoFree( io->crypto );
|
||||
|
|
Loading…
Reference in a new issue