python3: change call to urlparse

partial: https://github.com/vmware/pyvmomi/issues/55
This commit is contained in:
Kevin McCarthy
2014-07-25 10:32:22 -10:00
committed by Shawn Hartsock
parent a96438c0c1
commit f93ddf9d63

View File

@@ -28,7 +28,8 @@ import os
import socket
import subprocess
import time
from six.moves.urllib.parse import urlparse
from datetime import datetime
from xml.parsers.expat import ParserCreate
# We have our own escape functionality.
# from xml.sax.saxutils import escape
@@ -1136,7 +1137,7 @@ class SoapStubAdapter(SoapStubAdapterBase):
# the UnixSocketConnection ctor expects to find it -- see above
self.host = sock
elif url:
scheme, self.host, urlpath = urlparse(url)[:3]
scheme, self.host, urlpath = urlparse.urlparse(url)[:3]
# Only use the URL path if it's sensible, otherwise use the path
# keyword argument as passed in.
if urlpath not in ('', '/'):