From 3663b586644e6d2af1d682f0703ba0d1a80d53d7 Mon Sep 17 00:00:00 2001 From: Benjamin Peterson Date: Wed, 26 Nov 2014 14:39:54 -0600 Subject: [PATCH] correct assertion --- Python/codecs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Python/codecs.c b/Python/codecs.c index ff9d1dec468..a0a540304aa 100644 --- a/Python/codecs.c +++ b/Python/codecs.c @@ -1019,7 +1019,7 @@ PyObject *PyCodec_NameReplaceErrors(PyObject *exc) *outp++ = Py_hexdigits[c&0xf]; } - assert(outp == start + ressize); + assert(outp == PyUnicode_1BYTE_DATA(res) + ressize); assert(_PyUnicode_CheckConsistency(res, 1)); restuple = Py_BuildValue("(Nn)", res, end); Py_DECREF(object);