UDPProto: Fixed index-out-of-bounds bug

This commit is contained in:
Thomas Kolb 2021-03-18 21:22:30 +01:00
parent b683c8a391
commit 898ebbecc7

View file

@ -63,7 +63,7 @@ impl UdpProto
self.packet_offset += 7;
if self.packet_offset >= MAX_PACKET_LEN {
if self.packet_offset >= MAX_PACKET_LEN-7 {
self.send_packet()?;
}