summaryrefslogtreecommitdiff
path: root/src/StreamFileAllocationEntry.cc
diff options
context:
space:
mode:
authorTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2010-07-10 07:34:20 +0000
committerTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2010-07-10 07:34:20 +0000
commit8d2ca8e03cb13e0016c59ce4db4ed64a6bdd8d46 (patch)
tree7f533bfbc3fed66a66518b01652af0a786c87e67 /src/StreamFileAllocationEntry.cc
parent53c4de7ffdbf1631674ad2a7644b7062081444e2 (diff)
2010-07-10 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
Fixed the bug that DownloadContext::resetDownloadStartTime() never be called in downloads whose total length is unknown. This causes avg speed in Download Results is always 0 for these downloads. * src/RequestGroup.cc * src/BtFileAllocationEntry.cc * src/StreamFileAllocationEntry.cc
Diffstat (limited to 'src/StreamFileAllocationEntry.cc')
-rw-r--r--src/StreamFileAllocationEntry.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/StreamFileAllocationEntry.cc b/src/StreamFileAllocationEntry.cc
index e771e758..0194bcc0 100644
--- a/src/StreamFileAllocationEntry.cc
+++ b/src/StreamFileAllocationEntry.cc
@@ -59,6 +59,8 @@ void StreamFileAllocationEntry::prepareForNextAction
(std::vector<Command*>& commands,
DownloadEngine* e)
{
+ // For DownloadContext::resetDownloadStartTime(), see also
+ // RequestGroup::createInitialCommand()
getRequestGroup()->getDownloadContext()->resetDownloadStartTime();
if(getNextCommand()) {
// give _nextCommand a chance to execute in the next execution loop.