[yum-commits] Branch 'yum-3_2_X' - yum/__init__.py yum/sqlitesack.py

James Antill james at osuosl.org
Thu Mar 26 17:56:16 UTC 2009


 yum/__init__.py   |    7 +++++--
 yum/sqlitesack.py |    2 +-
 2 files changed, 6 insertions(+), 3 deletions(-)

New commits:
commit 6e5897f430be560fa15a1c276216eeb729dc7c94
Author: James Antill <james at and.org>
Date:   Thu Mar 26 13:56:08 2009 -0400

    Don't load filelists for provides 'perl(*net*)'

diff --git a/yum/__init__.py b/yum/__init__.py
index de1b3c5..396339e 100644
--- a/yum/__init__.py
+++ b/yum/__init__.py
@@ -1860,7 +1860,10 @@ class YumBase(depsolve.Depsolve):
                     canBeFile = True
             else:
                 isglob = True
-                canBeFile = True
+                if arg[0] != '/' and not misc.re_glob(arg[0]):
+                    canBeFile = False
+                else:
+                    canBeFile = True
                 
             if not isglob:
                 usedDepString = True
@@ -1883,7 +1886,7 @@ class YumBase(depsolve.Depsolve):
                     # then it is not a globbed file we have matched it precisely
                     tmpvalues.append(arg)
                     
-                if isglob:
+                if isglob and canBeFile:
                     self.verbose_logger.log(logginglevels.DEBUG_2,
                         _('searching in file entries'))
                     for thisfile in po.dirlist + po.filelist + po.ghostlist:
diff --git a/yum/sqlitesack.py b/yum/sqlitesack.py
index 0e8985d..d1a756d 100644
--- a/yum/sqlitesack.py
+++ b/yum/sqlitesack.py
@@ -934,7 +934,7 @@ class YumSqlitePackageSack(yumRepo.YumPackageSack):
         # If it's not a provides or a filename, we are done
         if prcotype != "provides":
             return results
-        if not glob and name[0] != '/':
+        if name[0] != '/' and (not glob or not misc.re_glob(name[0])):
             return results
 
         # If it is a filename, search the primary.xml file info


More information about the Yum-commits mailing list