diff options
author | Michael Vogt <michael.vogt@ubuntu.com> | 2011-08-08 15:25:43 +0200 |
---|---|---|
committer | Michael Vogt <michael.vogt@ubuntu.com> | 2011-08-08 15:25:43 +0200 |
commit | 29bc06137f829d51608fe697f3e27125d883fcef (patch) | |
tree | 7121486de1ce74a3e979f3dc0d6bc60b8a59dfe7 /apt-pkg/deb/deblistparser.cc | |
parent | f96bcef72c47ab32f4742da2673a12b3a47d8367 (diff) | |
parent | a1e9379a86f199817d275b2d28d1a6b61039fcaa (diff) |
merged from ubuntu-plus-debian-experimental
Diffstat (limited to 'apt-pkg/deb/deblistparser.cc')
-rw-r--r-- | apt-pkg/deb/deblistparser.cc | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/apt-pkg/deb/deblistparser.cc b/apt-pkg/deb/deblistparser.cc index 73628c741..59c4ee365 100644 --- a/apt-pkg/deb/deblistparser.cc +++ b/apt-pkg/deb/deblistparser.cc @@ -128,12 +128,7 @@ bool debListParser::NewVersion(pkgCache::VerIterator &Ver) } if (ArchitectureAll() == true) - switch (Ver->MultiArch) - { - case pkgCache::Version::Foreign: Ver->MultiArch = pkgCache::Version::AllForeign; break; - case pkgCache::Version::Allowed: Ver->MultiArch = pkgCache::Version::AllAllowed; break; - default: Ver->MultiArch = pkgCache::Version::All; - } + Ver->MultiArch |= pkgCache::Version::All; // Archive Size Ver->Size = Section.FindULL("Size"); @@ -690,12 +685,12 @@ bool debListParser::ParseProvides(pkgCache::VerIterator &Ver) if (MultiArchEnabled == false) return true; - else if (Ver->MultiArch == pkgCache::Version::Allowed || Ver->MultiArch == pkgCache::Version::AllAllowed) + else if ((Ver->MultiArch & pkgCache::Version::Allowed) == pkgCache::Version::Allowed) { string const Package = string(Ver.ParentPkg().Name()).append(":").append("any"); return NewProvidesAllArch(Ver, Package, Ver.VerStr()); } - else if (Ver->MultiArch == pkgCache::Version::Foreign || Ver->MultiArch == pkgCache::Version::AllForeign) + else if ((Ver->MultiArch & pkgCache::Version::Foreign) == pkgCache::Version::Foreign) return NewProvidesAllArch(Ver, Ver.ParentPkg().Name(), Ver.VerStr()); return true; |