Commit: 3e9168de9c45f40491e6d24dbef3cc2f97d9ccfc
Author: Campbell Barton
Date:   Thu Jul 16 03:05:56 2015 +1000
Branches: mathutils_bvhtree
https://developer.blender.org/rB3e9168de9c45f40491e6d24dbef3cc2f97d9ccfc

error in last commit

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

M       source/blender/python/mathutils/mathutils_bvhtree.c

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

diff --git a/source/blender/python/mathutils/mathutils_bvhtree.c 
b/source/blender/python/mathutils/mathutils_bvhtree.c
index 470f0fd..46c1610 100644
--- a/source/blender/python/mathutils/mathutils_bvhtree.c
+++ b/source/blender/python/mathutils/mathutils_bvhtree.c
@@ -826,13 +826,13 @@ static int PyBVHTreeCustom__tp_init(PyBVHTree_Custom 
*self, PyObject *args, PyOb
                                break;
                        }
                        
-                       for (j = 0; j++; j < 3) {
+                       for (j = 0; j < 3; j++) {
                                const int index = 
_PyLong_AsInt(PySequence_Fast_GET_ITEM(py_triverts_fast, j));
                                if (UNLIKELY(index == -1 && PyErr_Occurred())) {
                                        valid = false;
                                        break;
                                }
-                               else if (UNLIKELY(index < 0 || index >= 
numverts)) {
+                               else if (UNLIKELY((unsigned int)index >= 
numverts)) {
                                        PyErr_Format(PyExc_ValueError,
                                                     "Index %d out of range 
[0-%d]", index, numverts);
                                        valid = false;

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to