summaryrefslogtreecommitdiff
path: root/apt-pkg/pkgcachegen.cc
diff options
context:
space:
mode:
authorColin Watson <cjwatson@canonical.com>2012-10-14 23:54:21 +0100
committerColin Watson <cjwatson@canonical.com>2012-10-14 23:54:21 +0100
commit4a4a4449f9d83438f57dedc7628c76725d230449 (patch)
treeb9e680841e817da2b810a9c3ec4e2b2aadd3f7f8 /apt-pkg/pkgcachegen.cc
parentab0bbca93e3c2e923d3c1497712a0dc366f597ff (diff)
Cherry-pick from http://bzr.debian.org/bzr/apt/apt/debian-sid:
* apt-pkg/pkgcachegen.cc: - add a missing remap registration causing a segfault in case we use the not remapped iterators after a move of the mmap again
Diffstat (limited to 'apt-pkg/pkgcachegen.cc')
-rw-r--r--apt-pkg/pkgcachegen.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/apt-pkg/pkgcachegen.cc b/apt-pkg/pkgcachegen.cc
index 67018f057..03f8aea5a 100644
--- a/apt-pkg/pkgcachegen.cc
+++ b/apt-pkg/pkgcachegen.cc
@@ -722,6 +722,7 @@ unsigned long pkgCacheGenerator::NewVersion(pkgCache::VerIterator &Ver,
// Fill it in
Ver = pkgCache::VerIterator(Cache,Cache.VerP + Version);
+ Dynamic<pkgCache::VerIterator> DynV(Ver);
Ver->NextVer = Next;
Ver->ID = Cache.HeaderP->VersionCount++;
map_ptrloc const idxVerStr = WriteStringInMap(VerStr);