From 074564d40c21cb063bf327e9151a4e24cd9534b5 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Fri, 22 Jan 2016 02:00:42 +0100 Subject: use consistently the last : as name:arch separator Proper debian packages do not contain ':' in the package name, so for real packages this is a non-issue, but apt itself frequently makes use of packages with such an illegal name for internal proposes. Git-Dch: Ignore --- apt-pkg/pkgcachegen.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'apt-pkg/pkgcachegen.cc') diff --git a/apt-pkg/pkgcachegen.cc b/apt-pkg/pkgcachegen.cc index 6e307fba9..0dbac3df8 100644 --- a/apt-pkg/pkgcachegen.cc +++ b/apt-pkg/pkgcachegen.cc @@ -659,7 +659,7 @@ bool pkgCacheGenerator::NewPackage(pkgCache::PkgIterator &Pkg, StringView Name, // lazy-create foo (of amd64) provides foo:amd64 at the time we first need it if (Arch == "any") { - size_t const found = Name.find(':'); + size_t const found = Name.rfind(':'); StringView ArchA = Name.substr(found + 1); if (ArchA != "any") { -- cgit v1.2.3