Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/python/gpu/gpu_py_api.c')
-rw-r--r--source/blender/python/gpu/gpu_py_api.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/python/gpu/gpu_py_api.c b/source/blender/python/gpu/gpu_py_api.c
index 954118ffa5f..eb2fd1f7304 100644
--- a/source/blender/python/gpu/gpu_py_api.c
+++ b/source/blender/python/gpu/gpu_py_api.c
@@ -64,7 +64,7 @@ bool bpygpu_is_init_or_error(void)
int bpygpu_ParsePrimType(PyObject *o, void *p)
{
Py_ssize_t mode_id_len;
- const char *mode_id = _PyUnicode_AsStringAndSize(o, &mode_id_len);
+ const char *mode_id = PyUnicode_AsUTF8AndSize(o, &mode_id_len);
if (mode_id == NULL) {
PyErr_Format(PyExc_ValueError, "expected a string, got %s", Py_TYPE(o)->tp_name);
return 0;