diff options
author | Aldo Cortesi <aldo@nullcube.com> | 2012-06-24 16:20:50 +1200 |
---|---|---|
committer | Aldo Cortesi <aldo@nullcube.com> | 2012-06-24 16:20:50 +1200 |
commit | e6aa9ff67582c00d2de03f65b47dd776cd602fb7 (patch) | |
tree | 17015dd564bfeb15a9cf2bf2d63641a1032b94ae /libpathod/test.py | |
parent | 877b5a2d116c1ee0a8eb26191a65ff87f7146ae0 (diff) | |
download | mitmproxy-e6aa9ff67582c00d2de03f65b47dd776cd602fb7.tar.gz mitmproxy-e6aa9ff67582c00d2de03f65b47dd776cd602fb7.tar.bz2 mitmproxy-e6aa9ff67582c00d2de03f65b47dd776cd602fb7.zip |
Re-enable anchors.
Diffstat (limited to 'libpathod/test.py')
-rw-r--r-- | libpathod/test.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/libpathod/test.py b/libpathod/test.py index cb1b9745..00e03823 100644 --- a/libpathod/test.py +++ b/libpathod/test.py @@ -8,7 +8,7 @@ IFACE = "127.0.0.1" class Daemon: def __init__(self, staticdir=None, anchors=(), ssl=None): self.q = Queue.Queue() - self.thread = PaThread(self.q, ssl, staticdir) + self.thread = PaThread(self.q, staticdir, anchors, ssl) self.thread.start() self.port = self.q.get(True, 5) self.urlbase = "%s://%s:%s"%("https" if ssl else "http", IFACE, self.port) @@ -43,10 +43,9 @@ class Daemon: class PaThread(threading.Thread): - def __init__(self, q, ssl, staticdir): + def __init__(self, q, staticdir, anchors, ssl): threading.Thread.__init__(self) - self.q, self.ssl, self.staticdir = q, ssl, staticdir - self.port = None + self.q, self.staticdir, self.anchors, self.ssl = q, staticdir, anchors, ssl def run(self): if self.ssl is True: @@ -59,6 +58,7 @@ class PaThread(threading.Thread): self.server = pathod.Pathod( (IFACE, 0), ssloptions = ssloptions, + anchors = self.anchors, staticdir = self.staticdir ) self.q.put(self.server.port) |