summaryrefslogtreecommitdiff
path: root/cmdline/apt-get.cc
diff options
context:
space:
mode:
authorMichael Vogt <michael.vogt@ubuntu.com>2012-04-17 09:18:34 +0200
committerMichael Vogt <michael.vogt@ubuntu.com>2012-04-17 09:18:34 +0200
commit0325d83c4da93649763bbda3648b064b2cbe245c (patch)
tree148ce23b8b10a8f914f0516edfc13befde369818 /cmdline/apt-get.cc
parent443f5e8a3205162ec6933529c5ca0c95ad3f6941 (diff)
parent5ab7b53b09c508eb551eaf698bd2035cd3bc8777 (diff)
merged from lp:~donkult/apt/sid
Diffstat (limited to 'cmdline/apt-get.cc')
-rw-r--r--cmdline/apt-get.cc11
1 files changed, 7 insertions, 4 deletions
diff --git a/cmdline/apt-get.cc b/cmdline/apt-get.cc
index 4e6cc32de..dd9313bff 100644
--- a/cmdline/apt-get.cc
+++ b/cmdline/apt-get.cc
@@ -1679,10 +1679,13 @@ bool DoUpdate(CommandLine &CmdL)
ListUpdate(Stat, *List);
// Rebuild the cache.
- pkgCacheFile::RemoveCaches();
- if (Cache.BuildCaches() == false)
- return false;
-
+ if (_config->FindB("pkgCacheFile::Generate", true) == true)
+ {
+ pkgCacheFile::RemoveCaches();
+ if (Cache.BuildCaches() == false)
+ return false;
+ }
+
return true;
}
/*}}}*/