From 8b067c22e27a5939e45517091fbb8322ad7b71c8 Mon Sep 17 00:00:00 2001 From: Arch Librarian Date: Mon, 20 Sep 2004 16:55:11 +0000 Subject: 3 more bugs Author: jgg Date: 1999-11-16 03:16:34 GMT 3 more bugs --- cmdline/acqprogress.cc | 8 +++++--- cmdline/apt-get.cc | 9 ++++++++- 2 files changed, 13 insertions(+), 4 deletions(-) (limited to 'cmdline') diff --git a/cmdline/acqprogress.cc b/cmdline/acqprogress.cc index 2f7a9c4fc..0eb8d4b6f 100644 --- a/cmdline/acqprogress.cc +++ b/cmdline/acqprogress.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: acqprogress.cc,v 1.18 1999/10/18 03:18:40 jgg Exp $ +// $Id: acqprogress.cc,v 1.19 1999/11/16 03:16:34 jgg Exp $ /* ###################################################################### Acquire Progress - Command line progress meter @@ -145,10 +145,12 @@ bool AcqTextStatus::Pulse(pkgAcquire *Owner) enum {Long = 0,Medium,Short} Mode = Long; - char Buffer[300]; + char Buffer[1024]; char *End = Buffer + sizeof(Buffer); char *S = Buffer; - + if (ScreenWidth >= sizeof(Buffer)) + ScreenWidth = sizeof(Buffer)-1; + // Put in the percent done sprintf(S,"%ld%%",long(double((CurrentBytes + CurrentItems)*100.0)/double(TotalBytes+TotalItems))); diff --git a/cmdline/apt-get.cc b/cmdline/apt-get.cc index 217239b0d..0dd396a62 100644 --- a/cmdline/apt-get.cc +++ b/cmdline/apt-get.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: apt-get.cc,v 1.87 1999/10/28 05:54:45 jgg Exp $ +// $Id: apt-get.cc,v 1.88 1999/11/16 03:16:34 jgg Exp $ /* ###################################################################### apt-get - Cover for dpkg @@ -1228,6 +1228,13 @@ bool DoDSelectUpgrade(CommandLine &CmdL) /* */ bool DoClean(CommandLine &CmdL) { + if (_config->FindB("APT::Get::Simulate") == true) + { + cout << "Del " << _config->FindDir("Dir::Cache::archives") << "* " << + _config->FindDir("Dir::Cache::archives") << "partial/*" << endl; + return true; + } + // Lock the archive directory FileFd Lock; if (_config->FindB("Debug::NoLocking",false) == false) -- cgit v1.2.3