Ignore:
Timestamp:
12/01/21 16:52:24 (3 years ago)
Author:
ymipsl
Message:

tracking memory leak
Elements, views, and connectors are now managed with shared pointer.
YM

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS/dev/dev_ym/XIOS_COUPLING/src/distribution/local_view.cpp

    r1930 r2267  
    66namespace xios 
    77{ 
    8   CLocalView::CLocalView(CLocalElement* parent, CElementView::type type, const CArray<int,1>& indexView)  
     8  CLocalView::CLocalView(shared_ptr<CLocalElement> parent, CElementView::type type, const CArray<int,1>& indexView)  
    99                        : CDistributedView( parent, type, {{  parent->localRank_,  indexView }} ), 
    1010                          localRank_(parent->localRank_), 
     
    1515  } 
    1616 
    17   CLocalView::CLocalView(CLocalElement* parent, CElementView::type type, const CArray<bool,1>& maskView)  
     17  CLocalView::CLocalView(shared_ptr<CLocalElement> parent, CElementView::type type, const CArray<bool,1>& maskView)  
    1818                        : CDistributedView( parent, type, {{  parent->localRank_,  maskView }} ), 
    1919                          localRank_(parent->localRank_), 
     
    2424  } 
    2525 
    26   void CLocalView::sendRemoteElement(CRemoteConnector& connector, CContextClient* client, CEventClient& event, const CMessage& messageHeader) 
     26  void CLocalView::sendRemoteElement(shared_ptr<CRemoteConnector> connector, CContextClient* client, CEventClient& event, const CMessage& messageHeader) 
    2727  { 
    2828    int n = index_.numElements() ; 
     
    3636    CMessage message(messageHeader) ; 
    3737    message<<globalSize_ ; 
    38     connector.transferToServer(ind, client, event, message) ; 
     38    connector->transferToServer(ind, client, event, message) ; 
    3939  } 
    4040 
Note: See TracChangeset for help on using the changeset viewer.