mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-24 01:46:36 +02:00
cleanup send buffer
This commit is contained in:
parent
145e36925f
commit
1ce6ad5ccc
1 changed files with 7 additions and 3 deletions
|
@ -408,12 +408,16 @@ namespace stream
|
|||
packets.push_back (p);
|
||||
numMsgs--;
|
||||
}
|
||||
if (m_SendBuffer.eof () && m_SendHandler)
|
||||
if (m_SendBuffer.eof ())
|
||||
{
|
||||
m_SendBuffer.str(""); // clean up buffer
|
||||
if (m_SendHandler)
|
||||
{
|
||||
m_SendHandler (boost::system::error_code ());
|
||||
m_SendHandler = nullptr;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (packets.size () > 0)
|
||||
{
|
||||
if (m_SavedPackets.empty ()) // no NACKS
|
||||
|
|
Loading…
Add table
Reference in a new issue