static PyObject * python_api_log_warning(PyObject *self, PyObject *args) { PyObject *message = NULL; if (!PyArg_ParseTuple(args, "O", &message)) { Py_RETURN_NONE; } char *message_str = python_str_or_unicode_to_string(message); allow_python_threads(); api_log_warning(message_str); free(message_str); disable_python_threads(); Py_RETURN_NONE; }
static void c_api_log_warning(const char *message) { api_log_warning(message); }