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/domain_algorithm/domain_algorithm_interpolate.cpp

    r2006 r2270  
    2222 
    2323namespace xios { 
    24 CGenericAlgorithmTransformation* CDomainAlgorithmInterpolate::create(bool isSource, CGrid* gridDst, CGrid* gridSrc, 
     24shared_ptr<CGenericAlgorithmTransformation> CDomainAlgorithmInterpolate::create(bool isSource, CGrid* gridDst, CGrid* gridSrc, 
    2525                                                                     CTransformation<CDomain>* transformation, 
    2626                                                                     int elementPositionInGrid, 
     
    4040  int domainSrcIndex = elementPositionInGridSrc2DomainPosition[elementPositionInGrid]; 
    4141 
    42   return (new CDomainAlgorithmInterpolate(isSource, domainListDestP[domainDstIndex], domainListSrcP[domainSrcIndex], interpolateDomain)); 
     42  return make_shared<CDomainAlgorithmInterpolate>(isSource, domainListDestP[domainDstIndex], domainListSrcP[domainSrcIndex], interpolateDomain); 
    4343} 
    4444CATCH 
Note: See TracChangeset for help on using the changeset viewer.