summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2006-10-18 09:15:50 +0000
committerZac Medico <zmedico@gentoo.org>2006-10-18 09:15:50 +0000
commitc7ad5b145e7a52a96413dbeb1dc255b6e5ba5996 (patch)
tree5cfdf4fce0bcd8e6ed52191a19352005c4898f49
parentf02b2de300bb1654cc46c039bd175596017a9cae (diff)
downloadportage-c7ad5b145e7a52a96413dbeb1dc255b6e5ba5996.tar.gz
portage-c7ad5b145e7a52a96413dbeb1dc255b6e5ba5996.tar.bz2
portage-c7ad5b145e7a52a96413dbeb1dc255b6e5ba5996.zip
Fix --usepkg --newuse logic so that it doesn't throw a KeyError if there's no matching ebuild in the tree.
svn path=/main/trunk/; revision=4748
-rwxr-xr-xbin/emerge5
1 files changed, 4 insertions, 1 deletions
diff --git a/bin/emerge b/bin/emerge
index ea4162d6c..1bc29c916 100755
--- a/bin/emerge
+++ b/bin/emerge
@@ -1246,7 +1246,10 @@ class depgraph:
iuses = set(filter_iuse_defaults(
bindb.aux_get(myeb_pkg, ["IUSE"])[0].split()))
old_use = bindb.aux_get(myeb_pkg, ["USE"])[0].split()
- pkgsettings.setcpv(myeb_pkg, mydb=portdb)
+ mydb = None
+ if "--usepkgonly" not in self.myopts and myeb:
+ mydb = portdb
+ pkgsettings.setcpv(myeb, mydb=mydb)
now_use = pkgsettings["USE"].split()
forced_flags = set()
forced_flags.update(pkgsettings.useforce)