mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-12-26 07:59:35 -05:00
remove potential use of deleted item in rsRecogn
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8430 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
8cb423f20d
commit
d38068c4bc
@ -616,7 +616,6 @@ bool RsRecogn::createTagRequest(const RsTlvSecurityKey &key, const RsGxsId &id,
|
||||
uint32_t len = serialiser.size(item);
|
||||
char *buf = new char[len];
|
||||
bool serOk = serialiser.serialise(item, buf, &len);
|
||||
delete item;
|
||||
|
||||
if (serOk)
|
||||
{
|
||||
@ -632,9 +631,11 @@ bool RsRecogn::createTagRequest(const RsTlvSecurityKey &key, const RsGxsId &id,
|
||||
std::cerr << std::endl;
|
||||
item->print(std::cerr);
|
||||
#endif // DEBUG_RECOGN
|
||||
return false;
|
||||
}
|
||||
delete item;
|
||||
return false;
|
||||
}
|
||||
|
||||
delete item;
|
||||
return serOk;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user