public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] portage r12242 - main/branches/2.1.6/pym/portage/dbapi
@ 2008-12-12 21:50 Zac Medico (zmedico)
  0 siblings, 0 replies; only message in thread
From: Zac Medico (zmedico) @ 2008-12-12 21:50 UTC (permalink / raw
  To: gentoo-commits

Author: zmedico
Date: 2008-12-12 21:50:25 +0000 (Fri, 12 Dec 2008)
New Revision: 12242

Modified:
   main/branches/2.1.6/pym/portage/dbapi/bintree.py
Log:
Fix breakage in stale metadata logic inside binarytree._poplulate().
(trunk r12211)

Modified: main/branches/2.1.6/pym/portage/dbapi/bintree.py
===================================================================
--- main/branches/2.1.6/pym/portage/dbapi/bintree.py	2008-12-12 21:50:00 UTC (rev 12241)
+++ main/branches/2.1.6/pym/portage/dbapi/bintree.py	2008-12-12 21:50:25 UTC (rev 12242)
@@ -598,13 +598,14 @@
 							aux_cache[k] = d[k]
 						self.dbapi._aux_cache[mycpv] = aux_cache
 
+			for cpv in list(metadata):
+				if cpv not in pkg_paths:
+					del metadata[cpv]
+
 			# Do not bother to write the Packages index if $PKGDIR/All/ exists
 			# since it will provide no benefit due to the need to read CATEGORY
 			# from xpak.
 			if update_pkgindex and os.access(self.pkgdir, os.W_OK):
-				stale = [cpv for cpv in metadata if cpv not in self._pkg_paths]
-				for cpv in stale:
-					del metadata[cpv]
 				del pkgindex.packages[:]
 				pkgindex.packages.extend(metadata.itervalues())
 				self._update_pkgindex_header(pkgindex.header)




^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2008-12-12 21:50 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-12-12 21:50 [gentoo-commits] portage r12242 - main/branches/2.1.6/pym/portage/dbapi Zac Medico (zmedico)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox