From: Brad Hubbard Date: Thu, 13 Sep 2018 03:19:02 +0000 (+1000) Subject: mgr: Change signature of PyString_AsString to match return X-Git-Tag: v14.0.1~267^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F24092%2Fhead;p=ceph.git mgr: Change signature of PyString_AsString to match return PyUnicode_AsUTF8 now returns 'const char*' Fixes: http://tracker.ceph.com/issues/35984 Signed-off-by: Brad Hubbard --- diff --git a/src/mgr/PythonCompat.h b/src/mgr/PythonCompat.h index 745dad1a7e7..7bbaf9c43cd 100644 --- a/src/mgr/PythonCompat.h +++ b/src/mgr/PythonCompat.h @@ -13,7 +13,7 @@ inline PyObject* PyString_FromString(const char *v) { return PyUnicode_FromFormat("%s", v); } -inline char* PyString_AsString(PyObject *string) { +inline const char* PyString_AsString(PyObject *string) { return PyUnicode_AsUTF8(string); } inline long PyInt_AsLong(PyObject *io) {