[Bf-blender-cvs] [112a2c0627f] blender-v3.3-release: Fix error from 21ea4995585931ad54f51c1878c06c526c3355a5

Campbell Barton noreply at git.blender.org
Wed Aug 24 02:20:13 CEST 2022


Commit: 112a2c0627fad56a38030b080ef63fd9ffa4c90b
Author: Campbell Barton
Date:   Wed Aug 24 10:18:35 2022 +1000
Branches: blender-v3.3-release
https://developer.blender.org/rB112a2c0627fad56a38030b080ef63fd9ffa4c90b

Fix error from 21ea4995585931ad54f51c1878c06c526c3355a5

Was not using the absolute index for comparison,
breaking the id_management test.

===================================================================

M	source/blender/python/intern/bpy_rna.c

===================================================================

diff --git a/source/blender/python/intern/bpy_rna.c b/source/blender/python/intern/bpy_rna.c
index b22c5e60eb3..55c8285f509 100644
--- a/source/blender/python/intern/bpy_rna.c
+++ b/source/blender/python/intern/bpy_rna.c
@@ -2250,7 +2250,7 @@ static PyObject *pyrna_prop_collection_subscript_int(BPy_PropertyRNA *self, Py_s
   }
   else {
     /* No callback defined, just iterate and find the nth item. */
-    const int key = (int)keynum;
+    const int key = (int)keynum_abs;
     PyObject *result = NULL;
     bool found = false;
     CollectionPropertyIterator iter;



More information about the Bf-blender-cvs mailing list