diff --git a/libretroshare/src/gxs/rsgxsnetservice.cc b/libretroshare/src/gxs/rsgxsnetservice.cc index 451d09b0a..84ddb2e4e 100644 --- a/libretroshare/src/gxs/rsgxsnetservice.cc +++ b/libretroshare/src/gxs/rsgxsnetservice.cc @@ -65,7 +65,16 @@ RsGxsNetService::RsGxsNetService(uint16_t servType, RsGeneralDataService *gds, RsGxsNetService::~RsGxsNetService() { + RS_STACK_MUTEX(mNxsMutex) ; + for(TransactionsPeerMap::iterator it = mTransactions.begin();it!=mTransactions.end();++it) + { + for(TransactionIdMap::iterator it2 = it->second.begin();it2!=it->second.end();++it2) + delete it2->second ; + + it->second.clear() ; + } + mTransactions.clear() ; }