fixed proper deleting of pending transactions inside mutex to avoid concurrent thread to use them

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7713 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
csoler 2014-11-26 20:34:24 +00:00
parent e2daec7134
commit 705598b0b4

View File

@ -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() ;
}