diff options
author | Zac Medico <zmedico@gentoo.org> | 2008-06-10 05:31:48 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2008-06-10 05:31:48 +0000 |
commit | 148a587d0b6e1bea2ca7f798a13edacc756930ec (patch) | |
tree | c350093f61cf956d2d14d47912d2e3125e0a78f3 /pym | |
parent | Use isinstance() instead of handling TypeError. (diff) | |
download | portage-idfetch-148a587d0b6e1bea2ca7f798a13edacc756930ec.tar.gz portage-idfetch-148a587d0b6e1bea2ca7f798a13edacc756930ec.tar.bz2 portage-idfetch-148a587d0b6e1bea2ca7f798a13edacc756930ec.zip |
Add another sanity check in the owners cache.
svn path=/main/trunk/; revision=10640
Diffstat (limited to 'pym')
-rw-r--r-- | pym/portage/dbapi/vartree.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/pym/portage/dbapi/vartree.py b/pym/portage/dbapi/vartree.py index f5755548..a624958c 100644 --- a/pym/portage/dbapi/vartree.py +++ b/pym/portage/dbapi/vartree.py @@ -919,7 +919,10 @@ class vardbapi(dbapi): base_names = self._vardb._aux_cache["owners"]["base_names"] # Take inventory of all cached package hashes. - for hash_values in base_names.itervalues(): + for name, hash_values in base_names.items(): + if not isinstance(hash_values, dict): + del base_names[name] + continue cached_hashes.update(hash_values) # Create sets of valid package hashes and uncached packages. |