depgraph._complete_graph: old virt sanity check
authorZac Medico <zmedico@gentoo.org>
Wed, 20 Jun 2012 23:01:01 +0000 (16:01 -0700)
committerZac Medico <zmedico@gentoo.org>
Wed, 20 Jun 2012 23:01:01 +0000 (16:01 -0700)
pym/_emerge/depgraph.py

index ad28d695eee751014e1fe77bab247776a4a48b43..0c014bcfd6d7eb429254c9b625c1c63543e070ea 100644 (file)
@@ -4309,9 +4309,11 @@ class depgraph(object):
                                vardb = self._frozen_config.roots[
                                        node.root].trees["vartree"].dbapi
                                inst_pkg = vardb.match_pkgs(node.slot_atom)
-                               if inst_pkg and (inst_pkg[0] > node or inst_pkg[0] < node):
-                                       version_change = True
-                                       break
+                               if inst_pkg and inst_pkg[0].cp == node.cp:
+                                       inst_pkg = inst_pkg[0]
+                                       if inst_pkg < node or node < inst_pkg:
+                                               version_change = True
+                                               break
 
                        if version_change:
                                self._dynamic_config.myparams["complete"] = True