someone broke^Wfixed the ~ operator, so revisionMatch didn't work correctly
authorgenone <genone@gentoo.org>
Thu, 9 Dec 2004 17:37:16 +0000 (17:37 -0000)
committergenone <genone@gentoo.org>
Thu, 9 Dec 2004 17:37:16 +0000 (17:37 -0000)
svn path=/; revision=181

trunk/ChangeLog
trunk/src/glsa-check/glsa.py

index 6b9dc6d712ac1846ecf47ee7fe3ca57c683655da..eb59a92ad83f886548cb99f275230c6c819d6138 100644 (file)
@@ -1,3 +1,6 @@
+2004-12-09 Marius Mauch <genone@gentoo.org>
+       * glsa.py: Another stupid bug, this time revisionMatch() broke as ~foobar-rN isn't valid anymore
+
 2004-12-08 Marius Mauch <genone@gentoo.org>
        * equery: implemented the --category option
        * glsa-check: fixed the bug where it wanted to unnecessary merge masked packages
index 6759d50d02c48769397208b8e9a055c26b31a6cc..3928cbf33b7da3f931ee0c6d140e098ee2a1c046 100644 (file)
@@ -315,12 +315,12 @@ def revisionMatch(revisionAtom, portdb):
        @rtype:         list of strings
        @return:        a list with the matching versions
        """
-       mylist = portdb.match(revisionAtom[2:])
+       mylist = portdb.match(re.sub("-r[0-9]+$", "", revisionAtom[2:]))
        rValue = []
        for v in mylist:
                r1 = "\""+portage.pkgsplit(v)[-1]+"\""
                r2 = "\""+portage.pkgsplit(revisionAtom[3:])[-1]+"\""
-               if eval(r1+" "+revisionAtom[0:1]+" "+r2):
+               if eval(r1+" "+revisionAtom[0:2]+" "+r2):
                        rValue.append(v)
        return rValue