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/scalar_algorithm/scalar_algorithm_extract_axis.cpp

    r1999 r2270  
    1717 
    1818namespace xios { 
    19 CGenericAlgorithmTransformation* CScalarAlgorithmExtractAxis::create(bool isSource, CGrid* gridDst, CGrid* gridSrc, 
     19shared_ptr<CGenericAlgorithmTransformation> CScalarAlgorithmExtractAxis::create(bool isSource, CGrid* gridDst, CGrid* gridSrc, 
    2020                                                                     CTransformation<CScalar>* transformation, 
    2121                                                                     int elementPositionInGrid, 
     
    3535  int axisSrcIndex = elementPositionInGridSrc2AxisPosition[elementPositionInGrid]; 
    3636 
    37   return (new CScalarAlgorithmExtractAxis(isSource, scalarListDestP[scalarDstIndex], axisListSrcP[axisSrcIndex], extractAxis)); 
     37  return make_shared<CScalarAlgorithmExtractAxis>(isSource, scalarListDestP[scalarDstIndex], axisListSrcP[axisSrcIndex], extractAxis); 
    3838} 
    3939CATCH 
Note: See TracChangeset for help on using the changeset viewer.