Fix #9361, a2051ba: [Network] Off by one in CanWriteToPacket

Previously it did not allow writing a byte to a packet that was of size limit - 1 anymore.
pull/332/head
rubidium42 3 years ago committed by rubidium42
parent bf500c39c9
commit 845fded2a0

@ -98,7 +98,7 @@ void Packet::PrepareToSend()
*/
bool Packet::CanWriteToPacket(size_t bytes_to_write)
{
return this->Size() + bytes_to_write < this->limit;
return this->Size() + bytes_to_write <= this->limit;
}
/*

Loading…
Cancel
Save