]> git.saurik.com Git - apt.git/blobdiff - apt-private/acqprogress.cc
Merge branch 'debian/sid' into bugfix/update-progress-reporting
[apt.git] / apt-private / acqprogress.cc
index fe7a45e12e3ee5c2671b696abc599c40fbcd8c8a..ee6c4536f1c3ffb964dcb3d3c8d9a9e8af5b6aa1 100644 (file)
@@ -170,7 +170,7 @@ bool AcqTextStatus::Pulse(pkgAcquire *Owner)
       ScreenWidth = sizeof(Buffer)-1;
 
    // Put in the percent done
       ScreenWidth = sizeof(Buffer)-1;
 
    // Put in the percent done
-   sprintf(S,"%.0f%%",((CurrentBytes + CurrentItems)*100.0)/(TotalBytes+TotalItems));
+   sprintf(S,"%.0f%%", Percent);
 
    bool Shown = false;
    for (pkgAcquire::Worker *I = Owner->WorkersBegin(); I != 0;
 
    bool Shown = false;
    for (pkgAcquire::Worker *I = Owner->WorkersBegin(); I != 0;
@@ -267,7 +267,7 @@ bool AcqTextStatus::Pulse(pkgAcquire *Owner)
    else
       cout << '\r' << BlankLine << '\r' << Buffer << flush;
    if (_config->FindB("Apt::Color", false) == true)
    else
       cout << '\r' << BlankLine << '\r' << Buffer << flush;
    if (_config->FindB("Apt::Color", false) == true)
-      cout << _config->Find("APT::Color::Neutral");
+      cout << _config->Find("APT::Color::Neutral") << flush;
 
    memset(BlankLine,' ',strlen(Buffer));
    BlankLine[strlen(Buffer)] = 0;
 
    memset(BlankLine,' ',strlen(Buffer));
    BlankLine[strlen(Buffer)] = 0;