From 8ebc6f8a59ce86c9f67e594f59d8db621a6cc8d0 Mon Sep 17 00:00:00 2001 From: mkaay Date: Mon, 31 Jan 2011 22:54:39 +0100 Subject: proxy fix --- module/network/HTTPRequest.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'module/network/HTTPRequest.py') diff --git a/module/network/HTTPRequest.py b/module/network/HTTPRequest.py index 67d1e0f19..25563cd72 100644 --- a/module/network/HTTPRequest.py +++ b/module/network/HTTPRequest.py @@ -90,7 +90,8 @@ class HTTPRequest(): else: self.c.setopt(pycurl.PROXYTYPE, pycurl.PROXYTYPE_HTTP) - self.c.setopt(pycurl.PROXY, "%s:%s" % (proxy["address"], proxy["port"])) + self.c.setopt(pycurl.PROXY, proxy["address"]) + self.c.setopt(pycurl.PROXYPORT, proxy["port"]) if proxy["username"]: self.c.setopt(pycurl.PROXYUSERPWD, "%s:%s" % (proxy["username"], proxy["password"])) @@ -204,4 +205,4 @@ if __name__ == "__main__": url = "http://pyload.org" c = HTTPRequest() print c.load(url) - \ No newline at end of file + -- cgit v1.2.3