]> OCCT Git - occt-copy.git/commitdiff
0025361: Sample "Voxel" crashes during "Demo - Collisions" demonstration
authorvro <vro@opencascade.com>
Tue, 14 Oct 2014 04:28:47 +0000 (08:28 +0400)
committerbugmaster <bugmaster@opencascade.com>
Thu, 23 Oct 2014 12:26:59 +0000 (16:26 +0400)
Deletion of an array was incorrect.

src/Voxel/Voxel_CollisionDetection.cxx

index 884bb76a78b8df6e062edf8413aae440368f8d3c..bb974b3a3dccf609605e5e986f86df5ee14079e0 100644 (file)
@@ -271,7 +271,7 @@ void Voxel_CollisionDetection::Clear()
 {
   if (myVoxels)
   {
-    delete ((Voxel_BoolDS*)myVoxels);
+    delete[] ((Voxel_BoolDS*)myVoxels);
     myVoxels = 0;
   }
 }