From 64142298580e83b51845f016469e881b3a2538b2 Mon Sep 17 00:00:00 2001 From: Narayan Desai Date: Wed, 31 Aug 2005 21:37:18 +0000 Subject: simplefile fix (Logical change 1.291) git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@1160 ce84e21b-d406-0410-9b95-82705330c041 --- src/lib/Server/Generators/Pkgmgr.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/lib/Server/Generators/Pkgmgr.py b/src/lib/Server/Generators/Pkgmgr.py index ae82dc5d1..eb648d2f8 100644 --- a/src/lib/Server/Generators/Pkgmgr.py +++ b/src/lib/Server/Generators/Pkgmgr.py @@ -21,7 +21,7 @@ class PackageEntry(XMLFileBacked): if pkg.attrib.has_key("simplefile"): self.packages[pkg.get('name')] = deepcopy(pkg.attrib) # most attribs will be set from pkg - self.packages[pkg.get('name')]['uri'] = location.attrib['uri'] + self.packages[pkg.get('name')]['uri'] = "%s/%s" % (location.get('uri'), pkg.get('simplefile')) elif pkg.attrib.has_key("file"): mdata = self.rpm.match(pkg.get('file')) if not mdata: @@ -29,8 +29,8 @@ class PackageEntry(XMLFileBacked): continue pkgname = mdata.group('name') self.packages[pkgname] = mdata.groupdict() - self.packages[pkgname]['file'] = pkg.attrib['file'] - self.packages[pkgname]['uri'] = location.attrib['uri'] + self.packages[pkgname]['file'] = pkg.get('file') + self.packages[pkgname]['uri'] = location.get('uri') self.packages[pkgname]['type'] = 'rpm' else: self.packages[pkg.get('name')] = pkg.attrib -- cgit v1.2.3-1-g7c22