Bug #203316 - Fix isvalidatom() to properly detect invalid operators
authorZac Medico <zmedico@gentoo.org>
Fri, 11 Jan 2008 05:49:02 +0000 (05:49 -0000)
committerZac Medico <zmedico@gentoo.org>
Fri, 11 Jan 2008 05:49:02 +0000 (05:49 -0000)
used together with slot atoms. Thanks to Arfrever Frehtes Taifersar
Arahesis <Arfrever.FTA@GMail.Com> for the patch. (trunk r9166)

svn path=/main/branches/2.1.2/; revision=9174

pym/portage_dep.py

index c00da1163d790d41a0cffc025242cffb30ab7127..2ac6ada99b26f8cddd3bfe3615153297f0075f06 100644 (file)
@@ -394,7 +394,7 @@ def isvalidatom(atom, allow_blockers=False):
                return 0
        operator = get_operator(atom)
        if operator:
-               if operator[0] in "<>" and atom[-1] == "*":
+               if operator[0] in "<>" and remove_slot(atom).endswith("*"):
                        return 0
                if mycpv_cps and mycpv_cps[0] != "null":
                        # >=cat/pkg-1.0