mirror of
https://github.com/transmission/transmission
synced 2024-12-25 01:03:01 +00:00
make decrementing the torrent count the last thing we do when destroying a torrent.
This commit is contained in:
parent
05ca8403c6
commit
ec12220404
1 changed files with 2 additions and 2 deletions
|
@ -907,8 +907,6 @@ tr_torrentFree( tr_torrent_t * tor )
|
||||||
|
|
||||||
tr_sharedLock( h->shared );
|
tr_sharedLock( h->shared );
|
||||||
|
|
||||||
h->torrentCount--;
|
|
||||||
|
|
||||||
tr_rwClose( &tor->lock );
|
tr_rwClose( &tor->lock );
|
||||||
tr_cpClose( tor->completion );
|
tr_cpClose( tor->completion );
|
||||||
|
|
||||||
|
@ -931,6 +929,8 @@ tr_torrentFree( tr_torrent_t * tor )
|
||||||
|
|
||||||
tr_free( tor );
|
tr_free( tor );
|
||||||
|
|
||||||
|
h->torrentCount--;
|
||||||
|
|
||||||
tr_sharedUnlock( h->shared );
|
tr_sharedUnlock( h->shared );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue