Ignore:
Timestamp:
12/07/21 12:07:33 (3 years ago)
Author:
ymipsl
Message:

Tracking memory leak :
Tranformations and algorithms are now managed with shared_ptr.

YM

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS/dev/dev_ym/XIOS_COUPLING/src/transformation/axis_algorithm/axis_algorithm_extract.cpp

    r2255 r2270  
    1010 
    1111namespace xios { 
    12 CGenericAlgorithmTransformation* CAxisAlgorithmExtract::create(bool isSource, CGrid* gridDst, CGrid* gridSrc, 
     12shared_ptr<CGenericAlgorithmTransformation> CAxisAlgorithmExtract::create(bool isSource, CGrid* gridDst, CGrid* gridSrc, 
    1313                                                           CTransformation<CAxis>* transformation, 
    1414                                                           int elementPositionInGrid, 
     
    2828  int axisSrcIndex = elementPositionInGridSrc2AxisPosition[elementPositionInGrid]; 
    2929 
    30   return (new CAxisAlgorithmExtract(isSource, axisListDestP[axisDstIndex], axisListSrcP[axisSrcIndex], extractAxis)); 
     30  return make_shared<CAxisAlgorithmExtract>(isSource, axisListDestP[axisDstIndex], axisListSrcP[axisSrcIndex], extractAxis); 
    3131} 
    3232CATCH 
Note: See TracChangeset for help on using the changeset viewer.