From: Zac Medico Date: Wed, 18 Aug 2010 20:49:52 +0000 (-0700) Subject: Fix get_cycles() to handle None return value from shortest_path(). X-Git-Tag: v2.2_rc68~88 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=5cfe98ee7e1e01f1634a29deb01fcefc9d551797;p=portage.git Fix get_cycles() to handle None return value from shortest_path(). --- diff --git a/pym/portage/util/digraph.py b/pym/portage/util/digraph.py index 97f9c99b2..2849b8e2c 100644 --- a/pym/portage/util/digraph.py +++ b/pym/portage/util/digraph.py @@ -310,6 +310,8 @@ class digraph(object): shortest_path = None for child in self.child_nodes(node, ignore_priority): path = self.shortest_path(child, node, ignore_priority) + if path is None: + continue if not shortest_path or len(shortest_path) > len(path): shortest_path = path if shortest_path: