diff --git a/src/calibre/utils/icu_calibre_utils.h b/src/calibre/utils/icu_calibre_utils.h index 283a7f575d..d80a62da97 100644 --- a/src/calibre/utils/icu_calibre_utils.h +++ b/src/calibre/utils/icu_calibre_utils.h @@ -133,7 +133,7 @@ static UChar32* python_to_icu32(PyObject *obj, int32_t *osz) { #endif #ifndef NO_ICU_TO_PYTHON -static PyObject* icu_to_python(UChar *src, int32_t sz) { - return PyUnicode_DecodeUTF16((char*) src, sz * sizeof(UChar), "replace", NULL); +static PyObject* icu_to_python(const UChar *src, int32_t sz) { + return PyUnicode_DecodeUTF16((const char*) src, sz * sizeof(UChar), "replace", NULL); } #endif