mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-12-27 00:19:25 -05:00
fixed crash when trying to deserialize an empty buffer in rsrecogn
This commit is contained in:
parent
2f2715b240
commit
e913f3689a
@ -552,6 +552,9 @@ RsGxsRecognTagItem *RsRecogn::extractTag(const std::string &encoded)
|
||||
std::vector<uint8_t> buffer = Radix64::decode(encoded);
|
||||
pktsize = buffer.size();
|
||||
|
||||
if(buffer.empty())
|
||||
return NULL ;
|
||||
|
||||
RsGxsRecognSerialiser serialiser;
|
||||
RsItem *item = serialiser.deserialise(buffer.data(), &pktsize);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user