Fix off by one error introduced by me in recent commit 6948a2d

This commit is contained in:
Brecht Van Lommel
2023-06-13 20:23:47 +02:00
parent 89232d52db
commit f3c45f5b5a

View File

@@ -261,7 +261,7 @@ static int BPy_IDGroup_SetName(BPy_IDProperty *self, PyObject *value, void *UNUS
name = PyUnicode_AsUTF8AndSize(value, &name_size);
if (name_size + 1 >= MAX_IDPROP_NAME) {
if (name_size + 1 > MAX_IDPROP_NAME) {
PyErr_SetString(PyExc_TypeError, "string length cannot exceed 63 characters!");
return -1;
}