Bug 145398 - next torrent from queue is not started when "keep seeding after download is finished is disabled"
Summary: next torrent from queue is not started when "keep seeding after download is f...
Status: RESOLVED FIXED
Alias: None
Product: ktorrent
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Ivan Vasic
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-05-14 00:48 UTC by Christoph Burger-Scheidlin
Modified: 2007-06-01 19:36 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
fix queue manager update, if not keep_seeding (424 bytes, patch)
2007-05-30 11:11 UTC, Glen Masgai
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Christoph Burger-Scheidlin 2007-05-14 00:48:01 UTC
Version:           2.1.4 (using KDE KDE 3.5.6)
Installed from:    Ubuntu Packages
OS:                Linux

Prerequisites:
Maximum Downloads: 5
option "Keep seeding after download is finished" disabled.
>5 Torrents in the queue to be downloaded (managed by QM)

Observed Behavior:
Torrent 6 is not started after Torrent 1 has completed downloading (state transition from downloading -> download completed)

Expected Behavior:
Torrent 6 starts downloading after Torrent 1 finishes. This correct behavior happens when "keep seeding after download is finished" is enabled (state transition from downloading -> seeding).
Comment 1 Joris Guisson 2007-05-14 21:20:16 UTC
QM problem, so Ivan should take a look at it
Comment 2 Glen Masgai 2007-05-30 11:09:52 UTC
I also noticed this behaviour. The problem seems to be in  QueueManager::torrentFinished(). The funtcion returns, when  keep_seeding is false and the queue does not get updated. I made a patch, which fixes this in my opinion.
Comment 3 Glen Masgai 2007-05-30 11:11:55 UTC
Created attachment 20724 [details]
fix queue manager update, if not keep_seeding
Comment 4 Ivan Vasic 2007-06-01 19:36:35 UTC
SVN commit 670486 by ivasic:

Fixed "keed seeding" option.
Thanks to Glen Masgai for providing the patch.

BUG:145398

 M  +2 -4      queuemanager.cpp  


--- trunk/extragear/network/ktorrent/libktorrent/torrent/queuemanager.cpp #670485:670486
@@ -586,11 +586,9 @@
 //   if(max_seeds !=0 && max_seeds < getNumRunning(false,true))
 //    tc->stop(true);
 
-		if (!keep_seeding)
-			return;
+		if (keep_seeding)
+		    torrentAdded(tc, false, false);
 
-		torrentAdded(tc, false, false);
-
 		orderQueue();
 	}