Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 8e7282f

Browse files
committed
Major bug fix to properly pass HTTPS request to HTTP proxy when its provided. It works with both Python 2.4 and Python 2.5 now. It still crashes at httplib level with Python 2.6.
1 parent 440a52b commit 8e7282f

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

lib/request/proxy.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ def request(self, method, url, body=None, headers={}):
5757
self._real_host = host
5858
self._real_port = int(port)
5959

60-
httplib.HTTPConnection.request(self, method, url, body, headers)
60+
httplib.HTTPConnection.request(self, method, rest, body, headers)
6161

6262

6363
def connect(self):
@@ -89,7 +89,7 @@ def connect(self):
8989
class ProxyHTTPSConnection(ProxyHTTPConnection):
9090
default_port = 443
9191

92-
def __init__(self, host, port=None, key_file=None, cert_file=None, strict=None):
92+
def __init__(self, host, port=None, key_file=None, cert_file=None, strict=None, timeout=None):
9393
ProxyHTTPConnection.__init__(self, host, port)
9494
self.key_file = key_file
9595
self.cert_file = cert_file

0 commit comments

Comments
 (0)