[Yum-devel] [PATCH 2/2] fix in rangeCompare for where the item we're comparing it to has LESS than range for example: if e-1.0-0 in the range of E < 1.1

Seth Vidal skvidal at fedoraproject.org
Tue Aug 11 20:59:43 UTC 2009


There are probably more typeso f insanity here - and some more tests to define and I commented
about that in the code.
---
 rpmUtils/miscutils.py |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)

diff --git a/rpmUtils/miscutils.py b/rpmUtils/miscutils.py
index f494fc3..d76f3a8 100644
--- a/rpmUtils/miscutils.py
+++ b/rpmUtils/miscutils.py
@@ -173,8 +173,14 @@ def rangeCompare(reqtuple, provtuple):
         if reqf in ['GT', 'GE', 4, 12]:
             return 1
         if reqf in ['EQ', 8]:
-            if f in ['LE', 10]:
+            if f in ['LE', 10, 'LT', 2]:
                 return 1
+        # there is more to be done here to make sure it is right
+        # my brain melted trying to map these- skvidal 8/11/2009
+        if reqf in ['LT', 2]:
+            if f in ['LT', 2]:
+                return 1
+        
     if rc == 0:
         if reqf in ['GT', 4]:
             if f in ['GT', 'GE', 4, 12]:
-- 
1.6.2.5



More information about the Yum-devel mailing list