From f541057b7dde885d3aa2a4014721a37fa223a408 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sat, 29 Nov 2008 20:24:31 +0000 Subject: [PATCH] Add a sanity check inside depgraph._add_pkg() to ensure that the dependencies of the same package are never processed more than once. (trunk r12122) svn path=/main/branches/2.1.6/; revision=12123 --- pym/_emerge/__init__.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/pym/_emerge/__init__.py b/pym/_emerge/__init__.py index 8c3a89d49..7efcae784 100644 --- a/pym/_emerge/__init__.py +++ b/pym/_emerge/__init__.py @@ -4536,6 +4536,9 @@ class depgraph(object): #IUSE-aware emerge -> USE DEP aware depgraph #"no downgrade" emerge """ + # Ensure that the dependencies of the same package + # are never processed more than once. + previously_added = pkg in self.digraph # select the correct /var database that we'll be checking against vardbapi = self.trees[pkg.root]["vartree"].dbapi @@ -4688,7 +4691,8 @@ class depgraph(object): if args: depth = 0 pkg.depth = depth - dep_stack.append(pkg) + if not previously_added: + dep_stack.append(pkg) return 1 def _add_pkg_deps(self, pkg, allow_unsatisfied=False): -- 2.26.2