From cd260198f9e3392db3081fc33ff03d110806f30a Mon Sep 17 00:00:00 2001 From: Christophe Dumez Date: Sat, 27 Dec 2008 17:05:26 +0000 Subject: [PATCH] - Fixed remembering of paused torrents cleanly --- src/bittorrent.cpp | 8 ++------ src/qtorrenthandle.cpp | 4 ++-- src/qtorrenthandle.h | 2 +- 3 files changed, 5 insertions(+), 9 deletions(-) diff --git a/src/bittorrent.cpp b/src/bittorrent.cpp index 428e43ac5..f1ecdeb9b 100644 --- a/src/bittorrent.cpp +++ b/src/bittorrent.cpp @@ -456,11 +456,7 @@ void bittorrent::addTorrent(QString path, bool fromScanDir, QString from_url, bo p.duplicate_is_error = false; // Already checked p.auto_managed = false; // Because it is added in paused state // Adding torrent to bittorrent session - h = s->add_torrent(p); - // XXX: Workaround for http://code.rasterbar.com/libtorrent/ticket/454 - h.pause(false); - //Q_ASSERT(!h.is_auto_managed()); - //Q_ASSERT(h.is_paused()); + h = QTorrentHandle(s->add_torrent(p)); // Check if it worked if(!h.is_valid()) { // No need to keep on, it failed. @@ -806,7 +802,7 @@ void bittorrent::saveFastResumeData() { for(unsigned int i=0; i