Commit: 5121dacf9dc846d26ebb8d02288ae5048c3c98be
Author: Sergey Sharybin
Date:   Fri Aug 25 21:33:44 2017 +0200
Branches: master
https://developer.blender.org/rB5121dacf9dc846d26ebb8d02288ae5048c3c98be

Fix for fix (tm): Residue of the debug code

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

M       intern/mikktspace/mikktspace.c

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

diff --git a/intern/mikktspace/mikktspace.c b/intern/mikktspace/mikktspace.c
index b9de91e95c2..c52494a49f8 100644
--- a/intern/mikktspace/mikktspace.c
+++ b/intern/mikktspace/mikktspace.c
@@ -1679,8 +1679,8 @@ static void QuickSortEdges(SEdge * pSortBuffer, int 
iLeft, int iRight, const int
        }
        else if(iElems < 16) {
                int i, j;
-               for (i = 0; i < iElems; i++) {
-                       for (j = 0; j < iElems - 1; j++) {
+               for (i = 0; i < iElems - 1; i++) {
+                       for (j = 0; j < iElems - i - 1; j++) {
                                int index = iLeft + j;
                                if (pSortBuffer[index].array[channel] > 
pSortBuffer[index + 1].array[channel]) {
                                        sTmp = pSortBuffer[index];

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

Reply via email to