From a04cd1f9a580867d65be8f1ecb3eac25a86eb953 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Sun, 28 Feb 2010 19:45:05 +0100 Subject: Fix the PkgFileIterator Constructor which defaults to the wrong value. (0 instead of the HeaderP) This breaks the Cache Validation functionality as the end() doesn't test for NULL. (The fault was introduced with the rewriting of the CacheIterators) --- apt-pkg/cacheiterators.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'apt-pkg/cacheiterators.h') diff --git a/apt-pkg/cacheiterators.h b/apt-pkg/cacheiterators.h index a64326a44..28e062f3c 100644 --- a/apt-pkg/cacheiterators.h +++ b/apt-pkg/cacheiterators.h @@ -345,7 +345,8 @@ class pkgCache::PkgFileIterator : public Iterator // Constructors inline PkgFileIterator() : Iterator() {}; - inline PkgFileIterator(pkgCache &Owner,PackageFile *Trg = 0) : Iterator(Owner, Trg) {}; + inline PkgFileIterator(pkgCache &Owner) : Iterator(Owner, Owner.PkgFileP) {}; + inline PkgFileIterator(pkgCache &Owner,PackageFile *Trg) : Iterator(Owner, Trg) {}; }; /*}}}*/ // Version File /*{{{*/ -- cgit v1.2.3