Fix peer destructor bug from ticket #270. This bug dates back to r1419 in January... I'm surprised it hasn't been reported before now.

This commit is contained in:
Charles Kerr 2007-07-25 16:33:22 +00:00
parent feb85f8957
commit d259e7b65a
1 changed files with 2 additions and 1 deletions

View File

@ -299,7 +299,8 @@ void tr_peerDestroy( tr_peer_t * peer )
{
r = &peer->inRequests[i];
block = tr_block( r->index, r->begin );
tr_cpDownloaderRem( tor->completion, block );
if( tor != NULL )
tr_cpDownloaderRem( tor->completion, block );
}
tr_bitfieldFree( peer->bitfield );
tr_bitfieldFree( peer->blamefield );