diff options
author | David Kalnischkies <david@kalnischkies.de> | 2014-06-19 11:00:02 +0200 |
---|---|---|
committer | David Kalnischkies <david@kalnischkies.de> | 2014-09-27 00:09:09 +0200 |
commit | fe86debbae914b51d2799e7b24abfd1f944f8caf (patch) | |
tree | 8c97eca81decc53d63f6b74cef78eb3eef29d0cf /apt-private | |
parent | d36b27305dae21f9b3b6de056853ecd8bbd157e6 (diff) | |
download | apt-fe86debbae914b51d2799e7b24abfd1f944f8caf.tar.gz |
deprecate Pkg->Name in favor of Grp->Name
They both store the same information, so this field just takes up space
in the Package struct for no good reason. We mark it "just" as deprecated
instead of instantly removing it though as it isn't misleading like
Section was and is potentially used in the wild more often.
Diffstat (limited to 'apt-private')
-rw-r--r-- | apt-private/private-cachefile.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/apt-private/private-cachefile.cc b/apt-private/private-cachefile.cc index 5e955ac39..29e665245 100644 --- a/apt-private/private-cachefile.cc +++ b/apt-private/private-cachefile.cc @@ -32,8 +32,10 @@ int CacheFile::NameComp(const void *a,const void *b) const pkgCache::Package &A = **(pkgCache::Package **)a; const pkgCache::Package &B = **(pkgCache::Package **)b; + const pkgCache::Group * const GA = SortCache->GrpP + A.Group; + const pkgCache::Group * const GB = SortCache->GrpP + B.Group; - return strcmp(SortCache->StrP + A.Name,SortCache->StrP + B.Name); + return strcmp(SortCache->StrP + GA->Name,SortCache->StrP + GB->Name); } /*}}}*/ // CacheFile::Sort - Sort by name /*{{{*/ |