mirror of
https://github.com/Hopiu/linkchecker.git
synced 2026-05-09 15:14:45 +00:00
fix quoting
git-svn-id: https://linkchecker.svn.sourceforge.net/svnroot/linkchecker/trunk/linkchecker@877 e7d03fd6-7b0d-0410-9947-9c21f3af8025
This commit is contained in:
parent
4a2d2c444d
commit
10ddb75519
1 changed files with 5 additions and 1 deletions
|
|
@ -237,12 +237,16 @@ class HttpUrlData (ProxyUrlData):
|
|||
if self.urlConnection:
|
||||
self.closeConnection()
|
||||
self.urlConnection = self._getHTTPObject(host)
|
||||
# quote parts before submit
|
||||
map(quote, self.urlparts[2:5])
|
||||
if self.proxy:
|
||||
path = urlparse.urlunsplit(self.urlparts)
|
||||
else:
|
||||
path = urlparse.urlunsplit(('', '', self.urlparts[2],
|
||||
self.urlparts[3], self.urlparts[4]))
|
||||
self.urlConnection.putrequest(method, quote(path), skip_host=1)
|
||||
# unquote parts again
|
||||
map(unquote, self.urlparts[2:5])
|
||||
self.urlConnection.putrequest(method, path, skip_host=1)
|
||||
self.urlConnection.putheader("Host", host)
|
||||
# userinfo is from http://user@pass:host/
|
||||
if self.userinfo:
|
||||
|
|
|
|||
Loading…
Reference in a new issue