diff options
Diffstat (limited to 'Objects/unicodeobject.c')
-rw-r--r-- | Objects/unicodeobject.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c index 9c1705d..7aa5ff0 100644 --- a/Objects/unicodeobject.c +++ b/Objects/unicodeobject.c @@ -5150,12 +5150,7 @@ PyUnicode_EncodeUTF32(const Py_UNICODE *s, PyObject * PyUnicode_AsUTF32String(PyObject *unicode) { - const Py_UNICODE *wstr; - Py_ssize_t wlen; - wstr = PyUnicode_AsUnicodeAndSize(unicode, &wlen); - if (wstr == NULL) - return NULL; - return PyUnicode_EncodeUTF32(wstr, wlen, NULL, 0); + return _PyUnicode_EncodeUTF32(unicode, NULL, 0); } /* --- UTF-16 Codec ------------------------------------------------------- */ |