summaryrefslogtreecommitdiff
path: root/apt-pkg/acquire.cc
diff options
context:
space:
mode:
authorMichael Vogt <mvo@ubuntu.com>2014-04-16 16:34:01 +0200
committerMichael Vogt <mvo@ubuntu.com>2014-04-16 16:34:01 +0200
commitc62f7898b6f37b8e4b076ae3c40d56d22a884efe (patch)
tree1dbf7c5b5c1dcbe32cb3982a3325b349a7283d8e /apt-pkg/acquire.cc
parent1dca8dc55c1fcf4bda07a7e8285de7f225448697 (diff)
add Debug::acquire::progress debug option and fixme for index file loading with the correct extension
Diffstat (limited to 'apt-pkg/acquire.cc')
-rw-r--r--apt-pkg/acquire.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/apt-pkg/acquire.cc b/apt-pkg/acquire.cc
index 9fc40752f..46d5e6386 100644
--- a/apt-pkg/acquire.cc
+++ b/apt-pkg/acquire.cc
@@ -846,6 +846,7 @@ bool pkgAcquireStatus::Pulse(pkgAcquire *Owner)
unsigned long long ResumeSize = 0;
for (pkgAcquire::Worker *I = Owner->WorkersBegin(); I != 0;
I = Owner->WorkerStep(I))
+ {
if (I->CurrentItem != 0 && I->CurrentItem->Owner->Complete == false)
{
CurrentBytes += I->CurrentSize;
@@ -856,7 +857,14 @@ bool pkgAcquireStatus::Pulse(pkgAcquire *Owner)
I->CurrentItem->Owner->Complete == false)
TotalBytes += I->CurrentSize;
}
+ }
+ // debug
+ if (_config->FindB("Debug::acquire::progress", false) == true)
+ std::clog << " Bytes: "
+ << SizeToStr(CurrentBytes) << " / " << SizeToStr(TotalBytes)
+ << std::endl;
+
// Normalize the figures and account for unknown size downloads
if (TotalBytes <= 0)
TotalBytes = 1;