summaryrefslogtreecommitdiffstats
path: root/apt-pkg/tagfile.cc
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 10:17:41 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 10:17:41 +0000
commitf228636c02dc1bcb88704933b7e2049a31116d13 (patch)
tree2d923ac0acd8300f6e9f13f3fd0c85287565699e /apt-pkg/tagfile.cc
parentReleasing progress-linux version 2.7.13-0.0~progress7.99u1. (diff)
downloadapt-f228636c02dc1bcb88704933b7e2049a31116d13.tar.xz
apt-f228636c02dc1bcb88704933b7e2049a31116d13.zip
Merging upstream version 2.7.14.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'apt-pkg/tagfile.cc')
-rw-r--r--apt-pkg/tagfile.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/apt-pkg/tagfile.cc b/apt-pkg/tagfile.cc
index 8f323bb..95ae4a4 100644
--- a/apt-pkg/tagfile.cc
+++ b/apt-pkg/tagfile.cc
@@ -431,6 +431,11 @@ bool pkgTagFile::Fill()
that is there */
bool pkgTagFile::Jump(pkgTagSection &Tag,unsigned long long Offset)
{
+ // Head back to the start of the buffer, in case we get called for the same section
+ // again (d->Start will point to next section already)
+ d->iOffset -= d->Start - d->Buffer;
+ d->Start = d->Buffer;
+
if ((d->Flags & pkgTagFile::SUPPORT_COMMENTS) == 0 &&
// We are within a buffer space of the next hit..
Offset >= d->iOffset && d->iOffset + (d->End - d->Start) > Offset)