diff options
author | Zac Medico <zmedico@gentoo.org> | 2010-10-31 11:15:00 -0700 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2010-10-31 11:15:55 -0700 |
commit | bbce62ccae17b6db10ecd99e76589b7174f63f55 (patch) | |
tree | 56f7f4dc2238d2a6120978c393e3b8a6fa668ce5 /pym | |
parent | 8cf07e21b50e9912e569fc5258dd58aee6f0a5ef (diff) | |
download | portage-bbce62ccae17b6db10ecd99e76589b7174f63f55.tar.gz portage-bbce62ccae17b6db10ecd99e76589b7174f63f55.tar.bz2 portage-bbce62ccae17b6db10ecd99e76589b7174f63f55.zip |
Optimize LazyItemsDict.__deepcopy__().v2.1.9.24
Diffstat (limited to 'pym')
-rw-r--r-- | pym/portage/util/__init__.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pym/portage/util/__init__.py b/pym/portage/util/__init__.py index b7a6ed133..6c39f8952 100644 --- a/pym/portage/util/__init__.py +++ b/pym/portage/util/__init__.py @@ -1299,8 +1299,8 @@ class LazyItemsDict(UserDict): memo[id(self)] = result for k in self: k_copy = deepcopy(k, memo) - if k in self.lazy_items: - lazy_item = self.lazy_items[k] + lazy_item = self.lazy_items.get(k) + if lazy_item is not None: if not lazy_item.singleton: raise TypeError(_unicode_decode("LazyItemsDict " + \ "deepcopy is unsafe with lazy items that are " + \ |