1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2025-02-03 04:53:27 +00:00

Don't attach peers to inactive torrents (should fix the CLOSE_WAIT connection leaks)

This commit is contained in:
Eric Petit 2006-09-26 11:16:40 +00:00
parent c7265daeeb
commit 8a7edafb4e

View file

@ -828,6 +828,12 @@ static void acceptLoop( void * _h )
for( tor = h->torrentList; tor; tor = tor->next )
{
tr_lockLock( &tor->lock );
if( tor->status & TR_STATUS_INACTIVE )
{
tr_lockUnlock( &tor->lock );
continue;
}
if( 0 == memcmp( tor->info.hash, hash,
SHA_DIGEST_LENGTH ) )
{