summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2007-04-20 21:31:53 +0000
committerZac Medico <zmedico@gentoo.org>2007-04-20 21:31:53 +0000
commita981b183da38a3a85ed3e2938b7ce5640e6ef026 (patch)
treed83eb4be40d0182b852a129983f7aabab796f1f2
parentaa52fa26ca38c145fd34a15476bd042f027bde41 (diff)
downloadportage-a981b183da38a3a85ed3e2938b7ce5640e6ef026.tar.gz
portage-a981b183da38a3a85ed3e2938b7ce5640e6ef026.tar.bz2
portage-a981b183da38a3a85ed3e2938b7ce5640e6ef026.zip
For bug #175344, handle a potential InvalidDependString exception when parsing PROVIDE.
svn path=/main/trunk/; revision=6419
-rw-r--r--pym/emerge/__init__.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/pym/emerge/__init__.py b/pym/emerge/__init__.py
index 3a434fb0f..8dbe72b18 100644
--- a/pym/emerge/__init__.py
+++ b/pym/emerge/__init__.py
@@ -1542,8 +1542,14 @@ class depgraph:
if p_status == "merge":
# Update old-style virtuals if this package provides any.
# These are needed for dep_virtual calls inside dep_check.
- self.pkgsettings[p_root].setinst(p_key,
- self.trees[p_root][self.pkg_tree_map[p_type]].dbapi)
+ p_db = self.trees[p_root][self.pkg_tree_map[p_type]].dbapi
+ try:
+ self.pkgsettings[p_root].setinst(p_key, p_db)
+ except portage.exception.InvalidDependString, e:
+ provide = p_db.aux_get(p_key, ["PROVIDE"])[0]
+ show_invalid_depstring_notice(myparent, provide, str(e))
+ del e
+ return 0
if "--debug" in self.myopts:
print "Candidates:",mymerge