diff options
| author | Julian Andres Klode <julian.klode@canonical.com> | 2021-10-19 18:11:14 +0200 |
|---|---|---|
| committer | Julian Andres Klode <julian.klode@canonical.com> | 2021-10-19 18:25:51 +0200 |
| commit | 307912e8d74d9684875a791b0550c10afc14b0b0 (patch) | |
| tree | 3bb5a33c18a86b5527b1c83a6555d7828c355e9a /apt-pkg/pkgcache.cc | |
| parent | 9d9ccbbc685035e410e9f3dd5dd488a21d48661d (diff) | |
Invalidate cached architecture list when building cache
Fix a regression in python-apt where switching the architectures
in the config between cache invocations regressed.
Regression-Of: 8ff4e226af55a9feb168477a2b1a99f9c5152e54
Gbp-Dch: full
Diffstat (limited to 'apt-pkg/pkgcache.cc')
| -rw-r--r-- | apt-pkg/pkgcache.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/apt-pkg/pkgcache.cc b/apt-pkg/pkgcache.cc index 68efcaddc..0d18c6cf8 100644 --- a/apt-pkg/pkgcache.cc +++ b/apt-pkg/pkgcache.cc @@ -127,6 +127,10 @@ bool pkgCache::Header::CheckSizes(Header &Against) const /* */ pkgCache::pkgCache(MMap *Map, bool DoMap) : Map(*Map), VS(nullptr), d(NULL) { + // call getArchitectures() with cached=false to ensure that the + // architectures cache is re-evaluated. this is needed in cases + // when the APT::Architecture field changes between two cache creations + APT::Configuration::getArchitectures(false); MultiArchEnabled = true; if (DoMap == true) ReMap(); |
