Sophie

Sophie

distrib > Fedora > 14 > x86_64 > by-pkgid > 64e0c01f01117b1ae118340cd17642d0 > files > 10

apt-0.5.15lorg3.95-0.git416.6.fc14.1.src.rpm

Index: apt-pkg/pkgcachegen.cc
===================================================================
--- apt-pkg/pkgcachegen.cc	(revision 272)
+++ apt-pkg/pkgcachegen.cc	(working copy)
@@ -650,6 +650,17 @@
 	 continue;
       }
 
+      // Band-aid for cache corruption issue (RH bugzilla #211254) 
+      // until real cause and cure is found
+      for (pkgCache::PkgFileIterator File = Cache.FileBegin(); 
+	    File.end() == false; File++) {
+	 if (File.FileName() == NULL) {
+	    _error->Warning(_("Cache corruption detected, band-aid applied."));
+	    _error->Warning(_("See https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=211254 for further info."));
+	    return false;
+	 }
+      }
+
       // FindInCache is also expected to do an IMS check.
       pkgCache::PkgFileIterator File = (*Start)->FindInCache(Cache);
       if (File.end() == true)