View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0002698VTK(No Category)public2006-01-09 12:082016-07-06 09:17
ReporterSebastien Valette 
Assigned ToT.J. Corona 
PrioritynormalSeverityminorReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0002698: memory leak in vtkMath::SolveLeastSquares
DescriptionA memory leak was found in the method
int vtkMath::SolveLeastSquares(int numberOfSamples, double **xt, int xOrder,
                               double **yt, int yOrder, double **mt, int checkHomogeneous);

the intermediate variables are not released when this function returns 0;
Thus, the code:
*****************begin code**************
 // clean up:
  // set up intermediate variables
  for (i = 0; i < xOrder; i++)
    {
    delete [] XXt[i];
    delete [] XXtI[i];

    delete [] XYt[i];
    }
  delete [] XXt;
  delete [] XXtI;
  delete [] XYt;
  delete [] homogenFlags;
****************************************
should be inserted just before the return(0);
this bug seems to be present in all the versions
TagsNo tags attached.
Project
Type
Attached Files

 Relationships

  Notes
(0036155)
T.J. Corona (developer)
2016-07-06 09:17

Fixed in the following commit: https://gitlab.kitware.com/vtk/vtk/commit/66ea3751e7d9730cdc0cdeaed34f64bcfc49a89d [^]

 Issue History
Date Modified Username Field Change
2008-11-30 09:14 Mathieu Malaterre Assigned To Mathieu Malaterre => François Bertel
2010-09-07 13:46 François Bertel Assigned To François Bertel =>
2011-06-16 13:11 Zack Galbreath Category => (No Category)
2015-12-14 11:15 T.J. Corona Assigned To => T.J. Corona
2015-12-14 11:15 T.J. Corona Status expired => backlog
2015-12-14 11:15 T.J. Corona Status backlog => active development
2016-07-06 09:17 T.J. Corona Note Added: 0036155
2016-07-06 09:17 T.J. Corona Status active development => closed
2016-07-06 09:17 T.J. Corona Resolution open => fixed


Copyright © 2000 - 2018 MantisBT Team