fix checking issue with most pieces set to priority 0

This commit is contained in:
Arvid Norberg 2013-11-10 08:00:53 +00:00
parent 6136776097
commit 4521b8c902
1 changed files with 5 additions and 3 deletions

View File

@ -492,9 +492,6 @@ namespace libtorrent
m_obfuscated_hash = h.final();
#endif
#ifdef TORRENT_DEBUG
m_files_checked = false;
#endif
INVARIANT_CHECK;
if (p.flags & add_torrent_params::flag_sequential_download)
@ -6393,6 +6390,11 @@ namespace libtorrent
{
INVARIANT_CHECK;
if (m_state == torrent_status::checking_resume_data
|| m_state == torrent_status::checking_files
|| m_state == torrent_status::allocating)
return;
TORRENT_ASSERT(!is_finished());
set_state(torrent_status::downloading);
set_queue_position((std::numeric_limits<int>::max)());