[yum-cvs] yum/sqlitesack.py
Florian Festi
ffesti at linux.duke.edu
Thu Dec 20 12:35:50 UTC 2007
yum/sqlitesack.py | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
New commits:
commit 4c9fbd382b00a956a6e9086d340b4e0a243c9107
Author: Florian Festi <ffesti at redhat.com>
Date: Thu Dec 20 13:33:48 2007 +0100
Add strict param to SqliteSack.searchFiles - used in .getProvides()
diff --git a/yum/sqlitesack.py b/yum/sqlitesack.py
index f06a6d7..ed75d94 100644
--- a/yum/sqlitesack.py
+++ b/yum/sqlitesack.py
@@ -336,7 +336,7 @@ class YumSqlitePackageSack(yumRepo.YumPackageSack):
@catchSqliteException
- def searchFiles(self, name):
+ def searchFiles(self, name, strict=False):
"""search primary if file will be in there, if not, search filelists, use globs, if possible"""
# optimizations:
@@ -345,7 +345,7 @@ class YumSqlitePackageSack(yumRepo.YumPackageSack):
glob = True
querytype = 'glob'
- if not re.match('.*[\*\?\[\]].*', name):
+ if strict or not re.match('.*[\*\?\[\]].*', name):
glob = False
querytype = '='
@@ -526,7 +526,7 @@ class YumSqlitePackageSack(yumRepo.YumPackageSack):
if not matched: # if its not in the primary.xml files
# search the files.xml file info
- for pkg in self.searchFiles(name):
+ for pkg in self.searchFiles(name, strict=True):
result[pkg] = [(name, None, None)]
self._search_cache[prcotype][req] = result
return result
More information about the Yum-cvs-commits
mailing list