summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorChris St. Pierre <chris.a.st.pierre@gmail.com>2011-02-24 10:52:21 -0500
committerChris St. Pierre <chris.a.st.pierre@gmail.com>2011-02-24 10:52:21 -0500
commitfec3476b511912b0a8761499449ad23858eed362 (patch)
treee589e5231c451caa390037733baffb3576210f19 /src
parent086ff1838634a6b1358234d5c9ba9db295901828 (diff)
downloadbcfg2-fec3476b511912b0a8761499449ad23858eed362.tar.gz
bcfg2-fec3476b511912b0a8761499449ad23858eed362.tar.bz2
bcfg2-fec3476b511912b0a8761499449ad23858eed362.zip
YUMng: Fix handling of gpg-pubkey packages by yum 3.2.20 on SLES
Diffstat (limited to 'src')
-rw-r--r--src/lib/Client/Tools/YUMng.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/lib/Client/Tools/YUMng.py b/src/lib/Client/Tools/YUMng.py
index a97923881..f45a464f9 100644
--- a/src/lib/Client/Tools/YUMng.py
+++ b/src/lib/Client/Tools/YUMng.py
@@ -358,7 +358,12 @@ class YUMng(Bcfg2.Client.Tools.PkgTool):
for po in packages:
d = {}
for i in ['name', 'epoch', 'version', 'release', 'arch']:
- d[i] = getattr(po, i)
+ if i == 'arch' and getattr(po, i) is None:
+ d[i] = 'noarch'
+ elif i == 'epoch' and getattr(po, i) is None:
+ d[i] = '0'
+ else:
+ d[i] = getattr(po, i)
self.installed.setdefault(po.name, []).append(d)
def VerifyPackage(self, entry, modlist, pinned_version=None):