summaryrefslogtreecommitdiff
path: root/morphlib/remoteartifactcache.py
diff options
context:
space:
mode:
authorLars Wirzenius <lars.wirzenius@codethink.co.uk>2013-11-04 14:48:55 +0000
committerLars Wirzenius <lars.wirzenius@codethink.co.uk>2013-11-04 14:48:55 +0000
commitf92546e1179792512134ee51134db1107b7075e0 (patch)
tree0b264e98885e72cc9f036b138b802e372705551f /morphlib/remoteartifactcache.py
parent6a1d074bfd30d5d24faf02725542ec87509c310a (diff)
downloadmorph-f92546e1179792512134ee51134db1107b7075e0.tar.gz
Fix RemoteArtifactCache to quote filenames in URLs
This will allow fetching of gtk+ artifacts.
Diffstat (limited to 'morphlib/remoteartifactcache.py')
-rw-r--r--morphlib/remoteartifactcache.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/morphlib/remoteartifactcache.py b/morphlib/remoteartifactcache.py
index 17f547f2..c2f88773 100644
--- a/morphlib/remoteartifactcache.py
+++ b/morphlib/remoteartifactcache.py
@@ -16,6 +16,7 @@
import cliapp
import logging
+import urllib
import urllib2
import urlparse
@@ -108,7 +109,8 @@ class RemoteArtifactCache(object):
if not server_url.endswith('/'):
server_url += '/'
return urlparse.urljoin(
- server_url, '/1.0/artifacts?filename=%s' % filename)
+ server_url, '/1.0/artifacts?filename=%s' %
+ urllib.quote(filename))
def __str__(self): # pragma: no cover
return self.server_url