diff options
author | Aldo Cortesi <aldo@nullcube.com> | 2016-06-11 21:25:34 +1200 |
---|---|---|
committer | Aldo Cortesi <aldo@nullcube.com> | 2016-06-11 21:25:34 +1200 |
commit | 5566a1f0e68659c44e5dc03a1321cfb738c031c5 (patch) | |
tree | 9095ac83fb0023dd9d064d9c683a08f69b37f72b | |
parent | 0848d1085e28dd9f31ba0dddf042edc8c5955488 (diff) | |
download | mitmproxy-5566a1f0e68659c44e5dc03a1321cfb738c031c5.tar.gz mitmproxy-5566a1f0e68659c44e5dc03a1321cfb738c031c5.tar.bz2 mitmproxy-5566a1f0e68659c44e5dc03a1321cfb738c031c5.zip |
debug: num_fds is posix-only
-rw-r--r-- | netlib/debug.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/netlib/debug.py b/netlib/debug.py index 08ab2a44..8292d8d2 100644 --- a/netlib/debug.py +++ b/netlib/debug.py @@ -44,7 +44,8 @@ def dump_info(sig, frm, file=sys.stdout): # pragma: no cover print("Summary", file=file) print("=======", file=file) print("num threads: ", p.num_threads(), file=file) - print("num fds: ", p.num_fds(), file=file) + if hasattr(p, "num_fds"): + print("num fds: ", p.num_fds(), file=file) print("memory: ", p.memory_info(), file=file) print(file=file) |