diff options
author | Michael Vogt <michael.vogt@ubuntu.com> | 2011-08-09 14:38:01 +0200 |
---|---|---|
committer | Michael Vogt <michael.vogt@ubuntu.com> | 2011-08-09 14:38:01 +0200 |
commit | 216d0bd8869c4f52ead5256064512ac97e9fc824 (patch) | |
tree | ea6911a231e29b73a883d4449fe7f88941ddd92d /apt-pkg/deb/deblistparser.cc | |
parent | 629b60f6feea2d2d356645aa2615b212481bd3d8 (diff) | |
parent | 97efc27f0723f09405d7a1836ab21c2e2948eb10 (diff) |
merged from the debian-experimental2 branch
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; |