diff options
author | Aldo Cortesi <aldo@corte.si> | 2016-06-02 13:14:56 +1200 |
---|---|---|
committer | Aldo Cortesi <aldo@corte.si> | 2016-06-02 13:14:56 +1200 |
commit | 07f7905f9182ad0098a5a2e37d40ce9b27298380 (patch) | |
tree | 76ba04357353645f49e0f4bd8d835e471239b54b /pathod/utils.py | |
parent | eaa3b308f7bb48256ccf56ea07d008fa5f9dd6ad (diff) | |
parent | 09da1febbd9beac5ef5650274899439f5ce10e98 (diff) | |
download | mitmproxy-07f7905f9182ad0098a5a2e37d40ce9b27298380.tar.gz mitmproxy-07f7905f9182ad0098a5a2e37d40ce9b27298380.tar.bz2 mitmproxy-07f7905f9182ad0098a5a2e37d40ce9b27298380.zip |
Merge pull request #1191 from cortesi/utils
Utils reorganisation
Diffstat (limited to 'pathod/utils.py')
-rw-r--r-- | pathod/utils.py | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/pathod/utils.py b/pathod/utils.py index fe12f541..3276198a 100644 --- a/pathod/utils.py +++ b/pathod/utils.py @@ -2,8 +2,6 @@ import os import sys import netlib.utils -from netlib.utils import bytes_to_escaped_str - class MemBool(object): @@ -28,22 +26,6 @@ def parse_anchor_spec(s): return tuple(s.split("=", 1)) -def xrepr(s): - return repr(s)[1:-1] - - -def escape_unprintables(s): - """ - Like inner_repr, but preserves line breaks. - """ - s = s.replace(b"\r\n", b"PATHOD_MARKER_RN") - s = s.replace(b"\n", b"PATHOD_MARKER_N") - s = bytes_to_escaped_str(s) - s = s.replace("PATHOD_MARKER_RN", "\n") - s = s.replace("PATHOD_MARKER_N", "\n") - return s - - data = netlib.utils.Data(__name__) |