* apt-pkg/pkgcache.cc:
authorMichael Vogt <michael.vogt@ubuntu.com>
Fri, 30 Jul 2010 15:40:01 +0000 (17:40 +0200)
committerMichael Vogt <michael.vogt@ubuntu.com>
Fri, 30 Jul 2010 15:40:01 +0000 (17:40 +0200)
  - re-evaluate the architectures cache when the cache is (re)opened

apt-pkg/pkgcache.cc
debian/changelog

index 9e1f8b6..ae11057 100644 (file)
@@ -111,7 +111,10 @@ bool pkgCache::Header::CheckSizes(Header &Against) const
 /* */
 pkgCache::pkgCache(MMap *Map, bool DoMap) : Map(*Map)
 {
-   MultiArchEnabled = APT::Configuration::getArchitectures().size() > 1;
+   // call getArchitectures() with cached=false to ensure that the 
+   // architectures cache is re-evaulated. this is needed in cases
+   // when the APT::Architecture field changes between two cache creations
+   MultiArchEnabled = APT::Configuration::getArchitectures(false).size() > 1;
    if (DoMap == true)
       ReMap();
 }
index 33bd66b..cd0f4d7 100644 (file)
@@ -1,3 +1,11 @@
+apt (0.7.26~exp13) UNRELEASEDexperimental; urgency=low
+
+  [ Michael Vogt ]
+  * apt-pkg/pkgcache.cc:
+    - re-evaluate the architectures cache when the cache is (re)opened
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Fri, 30 Jul 2010 17:37:14 +0200
+
 apt (0.7.26~exp12) experimental; urgency=low
 
   [ Michael Vogt ]