Bug report for vtkRemoveDuplicatePolys
There is a bug in class vtkRemoveDuplicatePolys. In the vtkRemoveDuplicatePolys.cxx file at line 75, it new a new vtkIdList, i.e. vtkIdList* polyPoints = vtkIdList::New(); but at the end of this file, if there is not duplicated polys, the variable "ndup" is zero, then the variable "polyPoints" will not be deleted. Just change it to:
if (ndup)
{
vtkDebugMacro(<< "vtkRemoveDuplicatePolys : " << ndup
<< " duplicate polys (multiple instances of a polygon) have been"
<< " removed." << endl);
//polyPoints->Delete();
output->Squeeze();
}
polyPoints->Delete();