build system changes to eltopo, re-applied.
[blender.git] / extern / bullet2 / uninitialized_stack_vec.patch
1 Index: src/BulletCollision/CollisionShapes/btScaledBvhTriangleMeshShape.cpp
2 ===================================================================
3 --- src/BulletCollision/CollisionShapes/btScaledBvhTriangleMeshShape.cpp        (revision 34336)
4 +++ src/BulletCollision/CollisionShapes/btScaledBvhTriangleMeshShape.cpp        (working copy)
5 @@ -61,10 +61,12 @@
6         scaledAabbMin[0] = m_localScaling.getX() >= 0. ? aabbMin[0] * invLocalScaling[0] : aabbMax[0] * invLocalScaling[0];
7         scaledAabbMin[1] = m_localScaling.getY() >= 0. ? aabbMin[1] * invLocalScaling[1] : aabbMax[1] * invLocalScaling[1];
8         scaledAabbMin[2] = m_localScaling.getZ() >= 0. ? aabbMin[2] * invLocalScaling[2] : aabbMax[2] * invLocalScaling[2];
9 +       scaledAabbMin[3] = 0.0; /* otherwise un-initialized stack memory: uninitialized_stack_vec.patch, blender patch */
10         
11         scaledAabbMax[0] = m_localScaling.getX() <= 0. ? aabbMin[0] * invLocalScaling[0] : aabbMax[0] * invLocalScaling[0];
12         scaledAabbMax[1] = m_localScaling.getY() <= 0. ? aabbMin[1] * invLocalScaling[1] : aabbMax[1] * invLocalScaling[1];
13         scaledAabbMax[2] = m_localScaling.getZ() <= 0. ? aabbMin[2] * invLocalScaling[2] : aabbMax[2] * invLocalScaling[2];
14 +       scaledAabbMax[3] = 0.0; /* otherwise un-initialized stack memory: uninitialized_stack_vec.patch, blender patch */
15         
16         
17         m_bvhTriMeshShape->processAllTriangles(&scaledCallback,scaledAabbMin,scaledAabbMax);