when creating a torrent, initialize its cpStatus field before passing it to the torrent's worker thread
This commit is contained in:
parent
29c7ded0a3
commit
18aa394019
|
@ -222,6 +222,7 @@ torrentRealInit( tr_handle_t * h,
|
||||||
tor->error = TR_OK;
|
tor->error = TR_OK;
|
||||||
tor->runStatus = flags & TR_FLAG_PAUSED ? TR_RUN_STOPPED : TR_RUN_RUNNING;
|
tor->runStatus = flags & TR_FLAG_PAUSED ? TR_RUN_STOPPED : TR_RUN_RUNNING;
|
||||||
tor->recheckFlag = tr_ioCheckFiles( tor, TR_RECHECK_FAST );
|
tor->recheckFlag = tr_ioCheckFiles( tor, TR_RECHECK_FAST );
|
||||||
|
tor->cpStatus = tr_cpGetStatus( tor->completion );
|
||||||
|
|
||||||
tr_sharedLock( h->shared );
|
tr_sharedLock( h->shared );
|
||||||
tor->next = h->torrentList;
|
tor->next = h->torrentList;
|
||||||
|
|
Loading…
Reference in New Issue