mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-03-10 01:01:02 +00:00
cleanup send buffer
This commit is contained in:
parent
145e36925f
commit
1ce6ad5ccc
@ -408,10 +408,14 @@ namespace stream
|
||||
packets.push_back (p);
|
||||
numMsgs--;
|
||||
}
|
||||
if (m_SendBuffer.eof () && m_SendHandler)
|
||||
if (m_SendBuffer.eof ())
|
||||
{
|
||||
m_SendHandler (boost::system::error_code ());
|
||||
m_SendHandler = nullptr;
|
||||
m_SendBuffer.str(""); // clean up buffer
|
||||
if (m_SendHandler)
|
||||
{
|
||||
m_SendHandler (boost::system::error_code ());
|
||||
m_SendHandler = nullptr;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (packets.size () > 0)
|
||||
|
Loading…
x
Reference in New Issue
Block a user