summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar mkaay <mkaay@mkaay.de> 2010-05-07 23:03:49 +0200
committerGravatar mkaay <mkaay@mkaay.de> 2010-05-07 23:03:49 +0200
commit37a4eab603cb7e66d84c01407b2730a7aea96787 (patch)
tree2687bb1b3a89524cba62df5114e6893d88507e1d
parenthook fix (diff)
downloadpyload-37a4eab603cb7e66d84c01407b2730a7aea96787.tar.xz
added connection debugging
-rwxr-xr-xmodule/network/Request.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/module/network/Request.py b/module/network/Request.py
index a1d1f91c9..5d0871d47 100755
--- a/module/network/Request.py
+++ b/module/network/Request.py
@@ -64,6 +64,9 @@ class Request:
self.maxSpeed = 0
self.isSlow = False
self.cookieJar = None
+
+ # change this for connection information
+ self.debug = False
self.init_curl()
@@ -86,6 +89,9 @@ class Request:
self.pycurl.setopt(pycurl.HEADERFUNCTION, self.write_header)
self.pycurl.setopt(pycurl.BUFFERSIZE, self.bufferSize)
self.pycurl.setopt(pycurl.SSL_VERIFYPEER, 0)
+ self.pycurl.setopt(pycurl.ENCODING, "gzip, deflate")
+ if self.debug:
+ self.pycurl.setopt(pycurl.VERBOSE, 1)
self.pycurl.setopt(pycurl.USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en; rv:1.9.0.8) Gecko/2009032609 Firefox/3.0.10")