when creating a torrent, initialize its cpStatus field before passing it to the torrent's worker thread

This commit is contained in:
Charles Kerr 2007-07-02 01:29:05 +00:00
parent 29c7ded0a3
commit 18aa394019
1 changed files with 1 additions and 0 deletions

View File

@ -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;