Fix failure to catch errors parsing arguments to Context.temp_override

Resolve unhandled exception when invalid types for StructRNA arguments
were passed to temp_override(..).
This commit is contained in:
Campbell Barton
2024-05-08 23:13:50 +10:00
parent ad6e553ad8
commit 41efa30a75

View File

@@ -658,7 +658,7 @@ static PyObject *bpy_context_temp_override(PyObject *self, PyObject *args, PyObj
pyrna_struct_as_ptr_or_null_parse,
&params.region);
Py_DECREF(kwds_parse);
if (parse_result == -1) {
if (!parse_result) {
Py_DECREF(kwds);
return nullptr;
}