diff options
Diffstat (limited to 'Modules/_codecsmodule.c')
-rw-r--r-- | Modules/_codecsmodule.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_codecsmodule.c b/Modules/_codecsmodule.c index cd766c3..de5270d 100644 --- a/Modules/_codecsmodule.c +++ b/Modules/_codecsmodule.c @@ -172,7 +172,7 @@ escape_encode(PyObject *self, &PyString_Type, &str, &errors)) return NULL; - size = PyUnicode_GET_SIZE(str); + size = PyString_GET_SIZE(str); newsize = 4*size; if (newsize > PY_SSIZE_T_MAX || newsize / 4 != size) { PyErr_SetString(PyExc_OverflowError, |