diff options
Diffstat (limited to 'module/network/Request.py')
-rwxr-xr-x | module/network/Request.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/module/network/Request.py b/module/network/Request.py index 733ab5851..1fb76d7e0 100755 --- a/module/network/Request.py +++ b/module/network/Request.py @@ -32,7 +32,7 @@ class AbortDownload(Exception): pass class Request: - def __init__(self): + def __init__(self, interface=None): self.dl_time = 0 self.dl_finished = 0 @@ -64,6 +64,7 @@ class Request: self.maxSpeed = 0 self.isSlow = False self.cookieJar = None + self.interface = interface # change this for connection information self.debug = False @@ -91,6 +92,8 @@ class Request: self.pycurl.setopt(pycurl.SSL_VERIFYPEER, 0) if self.debug: self.pycurl.setopt(pycurl.VERBOSE, 1) + if self.interface: + self.pycurl.setopt(pycurl.INTERFACE, self.interface) 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") |