aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMaximilian Hils <git@maximilianhils.com>2015-09-17 02:39:07 +0200
committerMaximilian Hils <git@maximilianhils.com>2015-09-17 02:39:07 +0200
commit8fa01f41a6c821d29e595f89613d3bb1b5aabb58 (patch)
tree284f0fb384507fab35ee24754cd1f89363e66f8e
parentf61109db84a673caeaaabf9e3c7faedfd37b2b34 (diff)
downloadmitmproxy-8fa01f41a6c821d29e595f89613d3bb1b5aabb58.tar.gz
mitmproxy-8fa01f41a6c821d29e595f89613d3bb1b5aabb58.tar.bz2
mitmproxy-8fa01f41a6c821d29e595f89613d3bb1b5aabb58.zip
minor fixes
-rw-r--r--libpathod/protocols/websockets.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/libpathod/protocols/websockets.py b/libpathod/protocols/websockets.py
index 081a5248..134d27bc 100644
--- a/libpathod/protocols/websockets.py
+++ b/libpathod/protocols/websockets.py
@@ -1,7 +1,9 @@
import time
-from netlib import tcp, http, wsgi, certutils, websockets
-from .. import version, app, language, utils, log
+from netlib import websockets
+from .. import language
+from netlib.exceptions import NetlibException
+
class WebsocketsProtocol:
@@ -14,7 +16,7 @@ class WebsocketsProtocol:
started = time.time()
try:
frm = websockets.Frame.from_file(self.pathod_handler.rfile)
- except tcp.NetLibIncomplete as e:
+ except NetlibException as e:
lg("Error reading websocket frame: %s" % e)
break
ended = time.time()