From 53d2bc34fcb82fe3e483322064ef3c143ba5563f Mon Sep 17 00:00:00 2001 From: Christophe Dumez Date: Mon, 23 Jul 2007 08:32:06 +0000 Subject: [PATCH] - fixed minor code error in finishedList --- src/FinishedTorrents.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/FinishedTorrents.cpp b/src/FinishedTorrents.cpp index 53395f718..133791c2e 100644 --- a/src/FinishedTorrents.cpp +++ b/src/FinishedTorrents.cpp @@ -242,7 +242,7 @@ void FinishedTorrents::updateFinishedList(){ } torrent_status torrentStatus = h.status(); if(torrentStatus.state == torrent_status::downloading || (torrentStatus.state != torrent_status::checking_files && torrentStatus.state != torrent_status::queued_for_checking && torrentStatus.progress != 1.)) { - // What are you doing here, go back to download tab! + // What are you doing here? go back to download tab! qDebug("Info: a torrent was moved from finished to download tab"); deleteFromFinishedList(hash); emit torrentMovedFromFinishedList(h); @@ -278,6 +278,7 @@ void FinishedTorrents::deleteFromFinishedList(QString hash){ int row = getRowFromHash(hash); if(row == -1){ std::cerr << "Error: couldn't find hash in finished list\n"; + return; } finishedListModel->removeRow(row); QFile::remove(misc::qBittorrentPath()+"BT_backup"+QDir::separator()+hash+".finished");