mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-02-08 22:13:48 +01:00
fixe memory leak
This commit is contained in:
parent
598d0e216a
commit
266744f640
1 changed files with 2 additions and 1 deletions
|
@ -162,7 +162,8 @@ namespace stream
|
||||||
|
|
||||||
void Stream::SavePacket (Packet * packet)
|
void Stream::SavePacket (Packet * packet)
|
||||||
{
|
{
|
||||||
m_SavedPackets.insert (packet);
|
if (!m_SavedPackets.insert (packet).second)
|
||||||
|
delete packet;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Stream::ProcessPacket (Packet * packet)
|
void Stream::ProcessPacket (Packet * packet)
|
||||||
|
|
Loading…
Add table
Reference in a new issue