summaryrefslogtreecommitdiff
path: root/apt-pkg
diff options
context:
space:
mode:
Diffstat (limited to 'apt-pkg')
-rw-r--r--apt-pkg/pkgcache.h5
-rw-r--r--apt-pkg/pkgcachegen.cc11
2 files changed, 11 insertions, 5 deletions
diff --git a/apt-pkg/pkgcache.h b/apt-pkg/pkgcache.h
index d5d8fcad3..0b61b0048 100644
--- a/apt-pkg/pkgcache.h
+++ b/apt-pkg/pkgcache.h
@@ -604,8 +604,9 @@ struct pkgCache::VerFile
map_pointer<VerFile> NextFile;
/** \brief position in the package file */
map_filesize_t Offset; // File offset
- /** @TODO document pkgCache::VerFile::Size */
- map_filesize_t Size;
+#if APT_PKG_ABI <= 600
+ [[deprecated("No usage in src:apt, try MaxVerFileSize instead")]] map_filesize_t Size;
+#endif
};
/*}}}*/
// DescFile structure /*{{{*/
diff --git a/apt-pkg/pkgcachegen.cc b/apt-pkg/pkgcachegen.cc
index 76dea6266..055b2e08e 100644
--- a/apt-pkg/pkgcachegen.cc
+++ b/apt-pkg/pkgcachegen.cc
@@ -854,9 +854,14 @@ bool pkgCacheGenerator::NewFileVer(pkgCache::VerIterator &Ver,
*Last = VF.MapPointer();
VF->Offset = List.Offset();
- VF->Size = List.Size();
- if (Cache.HeaderP->MaxVerFileSize < VF->Size)
- Cache.HeaderP->MaxVerFileSize = VF->Size;
+ auto const Size = List.Size();
+ if (Cache.HeaderP->MaxVerFileSize < Size)
+ Cache.HeaderP->MaxVerFileSize = Size;
+#if APT_PKG_ABI <= 600
+ APT_IGNORE_DEPRECATED_PUSH
+ VF->Size = Size;
+ APT_IGNORE_DEPRECATED_POP
+#endif
Cache.HeaderP->VerFileCount++;
return true;