Disallow the operator= for btAlignedObjectArray, together with some fixes in the code (to avoid accidental deep copy)

Enable #define BT_ALLOW_ARRAY_COPY_OPERATOR in Bullet/LinearMath/btAlignedObjectArray.h to re-enable it
Fixes Issue 564, thanks to Tissen Peter for the report/fix
This commit is contained in:
erwin.coumans
2011-11-15 20:09:05 +00:00
parent d3c6f9dd67
commit 4e0aa42123
3 changed files with 17 additions and 4 deletions

View File

@@ -43,7 +43,7 @@ void btOptimizedBvh::build(btStridingMeshInterface* triangles, bool useQuantized
NodeTriangleCallback& operator=(NodeTriangleCallback& other)
{
m_triangleNodes = other.m_triangleNodes;
m_triangleNodes.copyFromArray(other.m_triangleNodes);
return *this;
}
@@ -84,7 +84,7 @@ void btOptimizedBvh::build(btStridingMeshInterface* triangles, bool useQuantized
QuantizedNodeTriangleCallback& operator=(QuantizedNodeTriangleCallback& other)
{
m_triangleNodes = other.m_triangleNodes;
m_triangleNodes.copyFromArray(other.m_triangleNodes);
m_optimizedTree = other.m_optimizedTree;
return *this;
}