From ceba1dc7341a2205e7893b5c9de09fb7eaf5563b Mon Sep 17 00:00:00 2001 From: sledgehammer999 Date: Thu, 16 Jan 2014 16:17:10 +0200 Subject: [PATCH] Don't count paused torrents for the autoshutdown. Closes #1280. --- src/qtlibtorrent/qbtsession.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/qtlibtorrent/qbtsession.cpp b/src/qtlibtorrent/qbtsession.cpp index 91fc71799..e403299eb 100755 --- a/src/qtlibtorrent/qbtsession.cpp +++ b/src/qtlibtorrent/qbtsession.cpp @@ -730,8 +730,9 @@ bool QBtSession::hasDownloadingTorrents() const { for ( ; torrentIT != torrentITend; ++torrentIT) { if (torrentIT->is_valid()) { try { - const torrent_status::state_t state = torrentIT->status().state; - if (state != torrent_status::finished && state != torrent_status::seeding) + const torrent_status status = torrentIT->status(); + if (status.state != torrent_status::finished && status.state != torrent_status::seeding + && !status.paused) return true; } catch(std::exception) {} }