Commit 935b19f3 authored by Ken Martin's avatar Ken Martin
Browse files

memory fix

parent de892f6b
......@@ -29,7 +29,7 @@
#include "vtkPointData.h"
#include "vtkCellData.h"
vtkCxxRevisionMacro(vtkDecimatePro, "1.73");
vtkCxxRevisionMacro(vtkDecimatePro, "1.73.2.1");
vtkStandardNewMacro(vtkDecimatePro);
#define VTK_TOLERANCE 1.0e-05
......@@ -978,6 +978,9 @@ void vtkDecimatePro::SplitVertex(vtkIdType ptId, int type,
//changes in group size control how to split loop
if ( numTris <= 1 )
{
triangles->Delete();
cellIds->Delete();
group->Delete();
return; //prevents infinite recursion
}
maxGroupSize = ( numTris < this->VertexDegree ? numTris : (this->VertexDegree - 1));
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment