diff options
author | Jenkins <jenkins@review.openstack.org> | 2013-08-22 21:12:47 +0000 |
---|---|---|
committer | Gerrit Code Review <review@openstack.org> | 2013-08-22 21:12:47 +0000 |
commit | 835638fd8ad4fb39be2161ee79057565809082ab (patch) | |
tree | 86f30672bef3a9c6a8482f166bc1f166ca369214 | |
parent | fe9a62b5b5681f3f8d467b24b8aca7ab646d1366 (diff) | |
parent | a30981e7f03317b1be06c05ff68833ffe3719fe0 (diff) | |
download | python-glanceclient-835638fd8ad4fb39be2161ee79057565809082ab.tar.gz |
Merge "Don't use posixpath for URLs"
-rw-r--r-- | glanceclient/common/http.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/glanceclient/common/http.py b/glanceclient/common/http.py index af3c0d0..4cd66ec 100644 --- a/glanceclient/common/http.py +++ b/glanceclient/common/http.py @@ -18,7 +18,6 @@ import errno import hashlib import httplib import logging -import posixpath import socket import StringIO import struct @@ -191,8 +190,8 @@ class HTTPClient(object): try: if self.endpoint_path: - url = '%s/%s' % (self.endpoint_path, url) - conn_url = posixpath.normpath(url) + url = urlparse.urljoin(self.endpoint_path, url) + conn_url = urlparse.urlsplit(url).geturl() # Note(flaper87): Ditto, headers / url # encoding to make httplib happy. conn_url = strutils.safe_encode(conn_url) |