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/intern/bpy_rna.c')
-rw-r--r--source/blender/python/intern/bpy_rna.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source/blender/python/intern/bpy_rna.c b/source/blender/python/intern/bpy_rna.c
index 65c701c0041..50e32f34594 100644
--- a/source/blender/python/intern/bpy_rna.c
+++ b/source/blender/python/intern/bpy_rna.c
@@ -1994,8 +1994,10 @@ static PyObject * pyrna_func_call(PyObject * self, PyObject *args, PyObject *kw)
/* Check if we gave args that dont exist in the function
* printing the error is slow but it should only happen when developing.
- * the if below is quick, checking if it passed less keyword args then we gave */
- if(kw && (PyDict_Size(kw) > kw_tot)) {
+ * the if below is quick, checking if it passed less keyword args then we gave.
+ * (Dont overwrite the error if we have one, otherwise can skip important messages and confuse with args)
+ */
+ if(err == 0 && kw && (PyDict_Size(kw) > kw_tot)) {
PyObject *key, *value;
Py_ssize_t pos = 0;