expand_new_virt: return early for non-virtual cat
authorZac Medico <zmedico@gentoo.org>
Thu, 12 May 2011 17:51:08 +0000 (10:51 -0700)
committerZac Medico <zmedico@gentoo.org>
Thu, 12 May 2011 17:51:08 +0000 (10:51 -0700)
pym/portage/dbapi/_expand_new_virt.py

index 6fccd164eb2f77da74bad08082713d2d0f01ef0a..6d6a27de803821cdb4b9c0b8f636c77bb5a2d569 100644 (file)
@@ -13,6 +13,11 @@ def expand_new_virt(vardb, atom):
        """
        if not isinstance(atom, Atom):
                atom = Atom(atom)
+
+       if not atom.cp.startswith("virtual/"):
+               yield atom
+               return
+
        traversed = set()
        stack = [atom]