Skip to content
Snippets Groups Projects
Commit 4b9412ec authored by Sean McBride's avatar Sean McBride Committed by Code Review
Browse files

Merge topic 'invalid-memory-use' into master

4dc4b4f9 Fixed use of memory after its deallocation
parents 915da191 4dc4b4f9
No related branches found
No related tags found
No related merge requests found
......@@ -734,6 +734,7 @@ void vtkKMeansStatistics::SelectAssessFunctor( vtkTable* inData,
if ( ! kmfunc->Initialize( inData, reqModel, this->DistanceFunctor ) )
{
delete kmfunc;
return;
}
dfunc = kmfunc;
}
......@@ -752,8 +753,8 @@ vtkKMeansAssessFunctor::~vtkKMeansAssessFunctor()
}
// ----------------------------------------------------------------------
bool vtkKMeansAssessFunctor::Initialize( vtkTable* inData,
vtkTable* inModel,
bool vtkKMeansAssessFunctor::Initialize( vtkTable* inData,
vtkTable* inModel,
vtkKMeansDistanceFunctor* dfunc )
{
vtkIdType numObservations = inData->GetNumberOfRows();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment