mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-12-28 08:59:37 -05:00
added missing delete in gxsnetservice
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8112 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
70918e9dcf
commit
28030f9b08
@ -1877,6 +1877,7 @@ void RsGxsNetService::locked_genReqMsgTransaction(NxsTransaction* tr)
|
|||||||
mDataStore->retrieveGxsGrpMetaData(grpMetaMap);
|
mDataStore->retrieveGxsGrpMetaData(grpMetaMap);
|
||||||
RsGxsGrpMetaData* grpMeta = grpMetaMap[grpId];
|
RsGxsGrpMetaData* grpMeta = grpMetaMap[grpId];
|
||||||
|
|
||||||
|
#warning TODO: what if grpMeta is NULL?
|
||||||
if(! (grpMeta->mSubscribeFlags & GXS_SERV::GROUP_SUBSCRIBE_SUBSCRIBED ))
|
if(! (grpMeta->mSubscribeFlags & GXS_SERV::GROUP_SUBSCRIBE_SUBSCRIBED ))
|
||||||
{
|
{
|
||||||
// For unsubscribed groups, we update the timestamp to now, so that the group content will not be asked to the same
|
// For unsubscribed groups, we update the timestamp to now, so that the group content will not be asked to the same
|
||||||
@ -1884,6 +1885,8 @@ void RsGxsNetService::locked_genReqMsgTransaction(NxsTransaction* tr)
|
|||||||
// That needs of course to reset that time to 0 when we subscribe.
|
// That needs of course to reset that time to 0 when we subscribe.
|
||||||
|
|
||||||
locked_stampPeerGroupUpdateTime(pid,grpId,time(NULL),msgItemL.size()) ;
|
locked_stampPeerGroupUpdateTime(pid,grpId,time(NULL),msgItemL.size()) ;
|
||||||
|
if(grpMeta)
|
||||||
|
delete grpMeta;
|
||||||
return ;
|
return ;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2062,6 +2065,8 @@ void RsGxsNetService::locked_genReqMsgTransaction(NxsTransaction* tr)
|
|||||||
|
|
||||||
locked_stampPeerGroupUpdateTime(pid,grpId,time(NULL),msgItemL.size()) ;
|
locked_stampPeerGroupUpdateTime(pid,grpId,time(NULL),msgItemL.size()) ;
|
||||||
}
|
}
|
||||||
|
if(grpMeta)
|
||||||
|
delete grpMeta;
|
||||||
}
|
}
|
||||||
|
|
||||||
void RsGxsNetService::locked_stampPeerGroupUpdateTime(const RsPeerId& pid,const RsGxsGroupId& grpId,time_t tm,uint32_t n_messages)
|
void RsGxsNetService::locked_stampPeerGroupUpdateTime(const RsPeerId& pid,const RsGxsGroupId& grpId,time_t tm,uint32_t n_messages)
|
||||||
|
Loading…
Reference in New Issue
Block a user