From: Marc-André Lemburg Date: Wed, 28 Nov 2001 12:56:20 +0000 (+0000) Subject: Fix for bug #485951: repr diff between string and unicode. X-Git-Tag: v2.2.1c1~685 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=11326de657e73d320f10150875cdbaea93d0680e;p=python Fix for bug #485951: repr diff between string and unicode. --- diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c index 142045514d..f7930208e7 100644 --- a/Objects/unicodeobject.c +++ b/Objects/unicodeobject.c @@ -1833,7 +1833,7 @@ PyObject *unicodeescape_string(const Py_UNICODE *s, } /* Map non-printable US ASCII to '\xhh' */ - else if (ch < ' ' || ch >= 128) { + else if (ch < ' ' || ch >= 0x7F) { *p++ = '\\'; *p++ = 'x'; *p++ = hexdigit[(ch >> 4) & 0x000F];