summaryrefslogtreecommitdiffstats
path: root/pym/portage/package/ebuild/config.py
diff options
context:
space:
mode:
Diffstat (limited to 'pym/portage/package/ebuild/config.py')
-rw-r--r--pym/portage/package/ebuild/config.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/pym/portage/package/ebuild/config.py b/pym/portage/package/ebuild/config.py
index 6b7af51e9..c8ea1c86e 100644
--- a/pym/portage/package/ebuild/config.py
+++ b/pym/portage/package/ebuild/config.py
@@ -1127,8 +1127,14 @@ class config(object):
repo_env = []
repo_env_empty = True
if repository and repository != Package.UNKNOWN_REPO:
- for repo in [repo.name for
- repo in self.repositories[repository].masters] + [repository]:
+ repos = []
+ try:
+ repos.extend(repo.name for repo in
+ self.repositories[repository].masters)
+ except KeyError:
+ pass
+ repos.append(repository)
+ for repo in repos:
d = self._repo_make_defaults.get(repo)
if d is None:
d = {}