From efcd69b009b391690693a429d6066d5be7cb6878 Mon Sep 17 00:00:00 2001 From: Arvid Norberg Date: Sun, 8 Jun 2008 13:47:35 +0000 Subject: [PATCH] fixed set_queue_position() for seeding (or finished) torrents --- src/torrent.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/torrent.cpp b/src/torrent.cpp index 8980879cb..73c89404a 100755 --- a/src/torrent.cpp +++ b/src/torrent.cpp @@ -3049,6 +3049,7 @@ namespace libtorrent { INVARIANT_CHECK; + TORRENT_ASSERT(!is_finished()); m_state = torrent_status::downloading; set_queue_position((std::numeric_limits::max)()); } @@ -3385,6 +3386,7 @@ namespace libtorrent void torrent::set_queue_position(int p) { + if (is_finished() && p != -1) return; if (p == m_sequence_number) return; session_impl::torrent_map& torrents = m_ses.m_torrents;