[Python-checkins] cpython: unicodeobject.c doesn't make output strings ready in debug mode
victor.stinner
python-checkins at python.org
Wed Oct 5 19:43:09 CEST 2011
http://hg.python.org/cpython/rev/78a2374e1d83
changeset: 72697:78a2374e1d83
user: Victor Stinner <victor.stinner at haypocalc.com>
date: Wed Oct 05 00:42:43 2011 +0200
summary:
unicodeobject.c doesn't make output strings ready in debug mode
Try to only create non ready strings in debug mode to ensure that all functions
(not only in unicodeobject.c, everywhere) make input strings ready.
files:
Objects/unicodeobject.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c
--- a/Objects/unicodeobject.c
+++ b/Objects/unicodeobject.c
@@ -46,6 +46,10 @@
#include <windows.h>
#endif
+#ifdef Py_DEBUG
+# define DONT_MAKE_RESULT_READY
+#endif
+
/* Limit for the Unicode object free list */
#define PyUnicode_MAXFREELIST 1024
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list