// ---------------------------------------------------------------------
/* This will return the Architecture of the package this section describes */
string debListParser::Architecture() {
// ---------------------------------------------------------------------
/* This will return the Architecture of the package this section describes */
string debListParser::Architecture() {
- for (;I != Stop && *I != ')'; I++);
- if (I == Stop || Start == I)
- return 0;
+ I = (const char*) memchr(I, ')', Stop - I);
+ if (I == NULL || Start == I)
+ return 0;
return _error->Error("Problem parsing Provides line");
if (Op != pkgCache::Dep::NoOp) {
_error->Warning("Ignoring Provides line with DepCompareOp for package %s", Package.c_str());
return _error->Error("Problem parsing Provides line");
if (Op != pkgCache::Dep::NoOp) {
_error->Warning("Ignoring Provides line with DepCompareOp for package %s", Package.c_str());
} else {
if (NewProvides(Ver, Package, Arch, Version) == false)
return false;
} else {
if (NewProvides(Ver, Package, Arch, Version) == false)
return false;
// file. to provide Component pinning we use the section name now
FileI->Component = WriteUniqString(component);
// file. to provide Component pinning we use the section name now
FileI->Component = WriteUniqString(component);