Dirty = false;
HeaderSz = sizeof(pkgCache::Header);
+ GroupSz = sizeof(pkgCache::Group);
PackageSz = sizeof(pkgCache::Package);
PackageFileSz = sizeof(pkgCache::PackageFile);
VersionSz = sizeof(pkgCache::Version);
VerFileSz = sizeof(pkgCache::VerFile);
DescFileSz = sizeof(pkgCache::DescFile);
+ GroupCount = 0;
PackageCount = 0;
VersionCount = 0;
DescriptionCount = 0;
bool pkgCache::Header::CheckSizes(Header &Against) const
{
if (HeaderSz == Against.HeaderSz &&
+ GroupSz == Against.GroupSz &&
PackageSz == Against.PackageSz &&
PackageFileSz == Against.PackageFileSz &&
VersionSz == Against.VersionSz &&
If any of the size values do not exactly match what the client expects
then the client should refuse the load the file. */
unsigned short HeaderSz;
+ unsigned short GroupSz;
unsigned short PackageSz;
unsigned short PackageFileSz;
unsigned short VersionSz;
map_ptrloc Name; // StringItem
// Linked List
- /** Link to the first package which belongs to the group */
+ /** \brief Link to the first package which belongs to the group */
map_ptrloc FirstPackage; // Package
- /** Link to the last package which belongs to the group */
+ /** \brief Link to the last package which belongs to the group */
map_ptrloc LastPackage; // Package
- /** Link to the next Group */
+ /** \brief Link to the next Group */
map_ptrloc Next; // Group
+ /** \brief unique sequel ID */
+ unsigned int ID;
+
};
/*}}}*/
// Package structure /*{{{*/
Grp->Next = Cache.HeaderP->GrpHashTable[Hash];
Cache.HeaderP->GrpHashTable[Hash] = Group;
- Cache.HeaderP->GroupCount++;
-
+ Grp->ID = Cache.HeaderP->GroupCount++;
return true;
}
/*}}}*/
use, extended_states and uri schemes.
* doc/cache.sgml:
- drop the file in favor of inplace documentation with doxygen
+ * apt-pkg/pkgcache.h:
+ - enhance the Groups ABI by providing a ID as the other structs does
+ - check also the size of the Group struct then checking for the others
[ Jari Aalto ]
* cmdline/apt-get.cc: