summaryrefslogtreecommitdiffstats
path: root/src/lib/Server/Plugins
diff options
context:
space:
mode:
authorNarayan Desai <desai@mcs.anl.gov>2009-09-09 20:08:38 +0000
committerNarayan Desai <desai@mcs.anl.gov>2009-09-09 20:08:38 +0000
commit9f9edcc6ed88e81522e452ae4b83a6c841bdd3b6 (patch)
treef7ff0e6d695c3b70b935b0259d4117d702607783 /src/lib/Server/Plugins
parent3e5ffe0ef35365b95009eeee110717cdd3e72aac (diff)
downloadbcfg2-9f9edcc6ed88e81522e452ae4b83a6c841bdd3b6.tar.gz
bcfg2-9f9edcc6ed88e81522e452ae4b83a6c841bdd3b6.tar.bz2
bcfg2-9f9edcc6ed88e81522e452ae4b83a6c841bdd3b6.zip
Packages: Make Packages handle urls not terminated with /'s properly (Resolves Ticket #716)
git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@5423 ce84e21b-d406-0410-9b95-82705330c041
Diffstat (limited to 'src/lib/Server/Plugins')
-rw-r--r--src/lib/Server/Plugins/Packages.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/lib/Server/Plugins/Packages.py b/src/lib/Server/Plugins/Packages.py
index 14958bbda..f3d958510 100644
--- a/src/lib/Server/Plugins/Packages.py
+++ b/src/lib/Server/Plugins/Packages.py
@@ -24,8 +24,12 @@ def source_from_xml(xsource):
ret['component'] = ['placeholder']
if xsource.find('RawURL') is not None:
ret['rawurl'] = xsource.find('RawURL').text
+ if not ret['rawurl'].endswith('/'):
+ ret['rawurl'] += '/'
else:
ret['url'] = xsource.find('URL').text
+ if not ret['url'].endswith('/'):
+ ret['url'] += '/'
return ret
class Source(object):