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_zoom.cpp

    r1998 r2270  
    77 
    88namespace xios { 
    9 CGenericAlgorithmTransformation* CDomainAlgorithmZoom::create(bool isSource, CGrid* gridDst, CGrid* gridSrc, 
     9shared_ptr<CGenericAlgorithmTransformation> CDomainAlgorithmZoom::create(bool isSource, CGrid* gridDst, CGrid* gridSrc, 
    1010                                                             CTransformation<CDomain>* transformation, 
    1111                                                             int elementPositionInGrid, 
     
    2525  int domainSrcIndex = elementPositionInGridSrc2DomainPosition[elementPositionInGrid]; 
    2626 
    27   return (new CDomainAlgorithmZoom(isSource, domainListDestP[domainDstIndex], domainListSrcP[domainSrcIndex], zoomDomain)); 
     27  return make_shared<CDomainAlgorithmZoom>(isSource, domainListDestP[domainDstIndex], domainListSrcP[domainSrcIndex], zoomDomain); 
    2828} 
    2929CATCH 
Note: See TracChangeset for help on using the changeset viewer.