mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-06-19 20:04:24 -04:00
fixed bug in accessing null pointer
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7236 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
3a18136678
commit
e3c6816713
2 changed files with 33 additions and 31 deletions
|
@ -307,6 +307,8 @@ RsGxsGrpMetaData* RsDataService::locked_getGrpMeta(RetroCursor &c)
|
|||
|
||||
if(data)
|
||||
ok &= grpMeta->keys.GetTlv(data, data_len, &offset);
|
||||
else
|
||||
grpMeta->keys.TlvClear() ;
|
||||
|
||||
// local meta
|
||||
grpMeta->mSubscribeFlags = c.getInt32(COL_GRP_SUBCR_FLAG);
|
||||
|
|
|
@ -1899,7 +1899,7 @@ void RsGenExchange::processGroupUpdatePublish()
|
|||
std::map<RsGxsGroupId, RsGxsGrpMetaData*>::iterator mit = grpMeta.find(groupId);
|
||||
|
||||
RsGxsGrpMetaData* meta = NULL;
|
||||
if(mit == grpMeta.end())
|
||||
if(mit == grpMeta.end() || mit->second == NULL)
|
||||
{
|
||||
std::cerr << "Error! could not find meta of old group to update!" << std::endl;
|
||||
mDataAccess->updatePublicRequestStatus(gup.mToken, RsTokenService::GXS_REQUEST_V2_STATUS_FAILED);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue