Fix TravisCI build failure.

This commit is contained in:
John Ralls 2018-09-18 15:07:47 -07:00
parent 0cf42a75b3
commit 59a6ebc33a

View File

@ -252,7 +252,8 @@ typedef char gchar;
for (i = size-1; i >= 0; i--) {
PyObject *o = PyList_GetItem($input, i);
if (PyUnicode_Check(o)) {
$1 = g_slist_prepend($1,PyUnicode_AsUTF8(PyList_GetItem($input, i)));
/* There's no way to preserve constness in GSList items. */
$1 = g_slist_prepend($1, (char*)PyUnicode_AsUTF8(PyList_GetItem($input, i)));
} else {
PyErr_SetString(PyExc_TypeError, "list must contain strings");
g_slist_free($1);