Show More
@@ -702,6 +702,9 b' DATA_ESCAPE_MAP.update({' | |||
|
702 | 702 | DATA_ESCAPE_RE = remod.compile(br'[\x00-\x08\x0a-\x1f\\\x7f-\xff]') |
|
703 | 703 | |
|
704 | 704 | def escapedata(s): |
|
705 | if isinstance(s, bytearray): | |
|
706 | s = bytes(s) | |
|
707 | ||
|
705 | 708 | return DATA_ESCAPE_RE.sub(lambda m: DATA_ESCAPE_MAP[m.group(0)], s) |
|
706 | 709 | |
|
707 | 710 | class fileobjectobserver(object): |
General Comments 0
You need to be logged in to leave comments.
Login now