unsigned long ETA =
(unsigned long)((TotalBytes - CurrentBytes) / CurrentCPS);
- snprintf(msg,sizeof(msg), _("Downloading file %li of %li (%s remaining)"), i, TotalItems, TimeToStr(ETA).c_str());
+ // only show the ETA if it makes sense
+ if (ETA > 0 && ETA < 172800 /* two days */ )
+ snprintf(msg,sizeof(msg), _("Downloading file %li of %li (%s remaining)"), i, TotalItems, TimeToStr(ETA).c_str());
+ else
+ snprintf(msg,sizeof(msg), _("Downloading file %li of %li"), i, TotalItems);
+
+
// build the status str
status << "dlstatus:" << i
+apt (0.6.43.4) unstable; urgency=low
+
+ * apt-pkg/acquire.cc: don't show ETA if it is 0 or absurdely large
+
+ --
+
apt (0.6.43.3) unstable; urgency=low
* Merge bubulle@debian.org--2005/apt--main--0 up to patch-186: