diff --git a/src/utils/PythonAPI.cpp b/src/utils/PythonAPI.cpp index 0d437b4f..d4e67ef6 100644 --- a/src/utils/PythonAPI.cpp +++ b/src/utils/PythonAPI.cpp @@ -22,7 +22,7 @@ PyObject *api_cmd(PyObject *self, PyObject *args) char *result = (char*) ""; if (PyArg_ParseTuple(args, "s:command", &command)) { - result = Core()->cmd(command).toUtf8().data(); + result = Core()->cmd(command).toLocal8Bit().data(); } return PyUnicode_FromString(result); } @@ -34,7 +34,7 @@ PyObject *api_cmdj(PyObject *self, PyObject *args) char *result = (char*) ""; if (PyArg_ParseTuple(args, "s:command", &command)) { - result = Core()->cmd(command).toUtf8().data(); + result = Core()->cmd(command).toLocal8Bit().data(); PyObject *jsonModule = PyImport_ImportModule("json"); PyObject *loadsFunc = PyObject_GetAttrString(jsonModule, "loads"); if (!PyCallable_Check(loadsFunc)) {