[yum-commits] 2 commits - yumcommands.py yum/updateinfo.py

James Antill james at osuosl.org
Mon May 13 18:13:48 UTC 2013


 yum/updateinfo.py |    7 ++++++-
 yumcommands.py    |    2 ++
 2 files changed, 8 insertions(+), 1 deletion(-)

New commits:
commit 3bdece0d770d88972f65561c36c04bad85c06c88
Author: James Antill <james at and.org>
Date:   Mon May 13 13:55:11 2013 -0400

    FNMatch CVEs/BZs in upi cmds, use fnmatch() for advisories in cmds.

diff --git a/yum/updateinfo.py b/yum/updateinfo.py
index 8c6e295..c0a5094 100644
--- a/yum/updateinfo.py
+++ b/yum/updateinfo.py
@@ -35,8 +35,13 @@ def _match_sec_cmd(sec_cmds, pkgname, notice):
     for i in sec_cmds:
         if fnmatch.fnmatch(pkgname, i):
             return i
-        if notice['update_id'] == i:
+        if fnmatch.fnmatch(notice['update_id'], i):
             return i
+        for ref in _ysp_safe_refs(notice['references']):
+            if ref['id'] is None:
+                continue
+            if fnmatch.fnmatch(ref['id'], i):
+                return i
     return None
 
 def _has_id(used_map, refs, ref_type, ref_ids):
commit 9744a7728acfa4ff79fcdae4004201f5dfcdba2c
Author: James Antill <james at and.org>
Date:   Mon May 13 14:00:20 2013 -0400

    Allow <upinfo list all cves>, because it's confusing.

diff --git a/yumcommands.py b/yumcommands.py
index 0407c92..f193cee 100644
--- a/yumcommands.py
+++ b/yumcommands.py
@@ -4020,6 +4020,8 @@ class UpdateinfoCommand(YumCommand):
         list_type = "available"
         if extcmds and extcmds[0] in ("updates","available","installed", "all"):
             list_type = extcmds.pop(0)
+            if filt_type is None:
+                extcmds, show_type, filt_type = self._parse_extcmds(extcmds)
 
         if filt_type == "newpackage":
             # No filtering here, as we want what isn't installed...


More information about the Yum-commits mailing list