summaryrefslogtreecommitdiffstats
path: root/Objects/object.c
diff options
context:
space:
mode:
authorAnthony Baxter <anthonybaxter@gmail.com>2006-03-30 10:53:17 (GMT)
committerAnthony Baxter <anthonybaxter@gmail.com>2006-03-30 10:53:17 (GMT)
commit262c00a21e4fff85b8d4cad95256684fa219d5e2 (patch)
tree462941320bd222eb01e09afa4989c8245b55fb0a /Objects/object.c
parent80a5d017906f6d3111da619e686a49ecc938cb12 (diff)
downloadcpython-262c00a21e4fff85b8d4cad95256684fa219d5e2.zip
cpython-262c00a21e4fff85b8d4cad95256684fa219d5e2.tar.gz
cpython-262c00a21e4fff85b8d4cad95256684fa219d5e2.tar.bz2
Fixed bug #1459029 - unicode reprs were double-escaped.
Backed out an old patch from 2000.
Diffstat (limited to 'Objects/object.c')
-rw-r--r--Objects/object.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/object.c b/Objects/object.c
index 3404c35..63fb4fd 100644
--- a/Objects/object.c
+++ b/Objects/object.c
@@ -316,7 +316,7 @@ PyObject_Repr(PyObject *v)
#ifdef Py_USING_UNICODE
if (PyUnicode_Check(res)) {
PyObject* str;
- str = PyUnicode_AsUnicodeEscapeString(res);
+ str = PyUnicode_AsEncodedString(res, NULL, NULL);
Py_DECREF(res);
if (str)
res = str;