// -*- mode: cpp; mode: fold -*-
// Description /*{{{*/
-// $Id: deblistparser.cc,v 1.16 1999/02/08 07:30:50 jgg Exp $
+// $Id: deblistparser.cc,v 1.18 1999/04/12 19:16:11 jgg Exp $
/* ######################################################################
Package Cache Generator - Generator for the cache structure.
Pkg->Section = UniqFindTagWrite("Section");
if (Section.FindFlag("Essential",Pkg->Flags,pkgCache::Flag::Essential) == false)
return false;
- if (Section.FindFlag("Immediate-Configure",Pkg->Flags,pkgCache::Flag::ImmediateConf) == false)
+ if (Section.FindFlag("Important",Pkg->Flags,pkgCache::Flag::Important) == false)
return false;
+
+ if (strcmp(Pkg.Name(),"apt") == 0)
+ Pkg->Flags |= pkgCache::Flag::Important;
+
if (ParseStatus(Pkg,Ver) == false)
return false;
return true;
if (I == Stop || Start == I)
return 0;
- Ver = string(Start,I-Start);
+ // Skip trailing whitespace
+ const char *End = I;
+ for (; End > Start && isspace(End[-1]); End--);
+
+ Ver = string(Start,End-Start);
I++;
}
else