Fix another potential 'RuntimeError: dictionary changed size during iteration'
authorZac Medico <zmedico@gentoo.org>
Tue, 22 Sep 2009 03:57:58 +0000 (03:57 -0000)
committerZac Medico <zmedico@gentoo.org>
Tue, 22 Sep 2009 03:57:58 +0000 (03:57 -0000)
exception in _owners_db._populate() for py3k.

svn path=/main/trunk/; revision=14375

pym/portage/dbapi/vartree.py

index 8d0256c126a00f49820858bb57bcdb86bba7e052..be69aab092573605ef89a80843f0a89123c24351 100644 (file)
@@ -1515,7 +1515,7 @@ class vardbapi(dbapi):
                        base_names = self._vardb._aux_cache["owners"]["base_names"]
 
                        # Take inventory of all cached package hashes.
-                       for name, hash_values in base_names.items():
+                       for name, hash_values in list(base_names.items()):
                                if not isinstance(hash_values, dict):
                                        del base_names[name]
                                        continue