From 727a381fc902cd93d23b3624359bad38d49539d0 Mon Sep 17 00:00:00 2001 From: Matthias Hoelzl Date: Wed, 4 Oct 2017 23:21:32 +0200 Subject: Fix Python 3 build - Take care of the differences in handling unicode characters in `escape_string` (formerly in `editor/SCsub`, now in `compat.py)`. - Conditionally include `_winreg` or `winreg` in the Mono editor module. --- editor/SCsub | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) (limited to 'editor/SCsub') diff --git a/editor/SCsub b/editor/SCsub index 11cdb471a8..e44b4e4bb2 100644 --- a/editor/SCsub +++ b/editor/SCsub @@ -4,18 +4,8 @@ Import('env') env.editor_sources = [] import os -from compat import encode_utf8, byte_to_str, open_utf8 - -def escape_string(s, encoding='ascii'): - if isinstance(s, unicode): - s = s.encode(encoding) - result = '' - for c in s: - if not (32 <= ord(c) < 127) or c in ('\\', '"'): - result += '\\%03o' % ord(c) - else: - result += c - return result +from compat import encode_utf8, byte_to_str, open_utf8, escape_string + def make_certs_header(target, source, env): -- cgit v1.2.3