mirror of
https://github.com/thelsing/knx.git
synced 2024-12-18 19:08:18 +01:00
drop unexpected udp data packet length
This commit is contained in:
parent
6eb7af74a0
commit
4f0e47f809
@ -517,11 +517,10 @@ int RP2040ArduinoPlatform::readBytesMultiCast(uint8_t* buffer, uint16_t maxLen)
|
|||||||
|
|
||||||
if (len > maxLen)
|
if (len > maxLen)
|
||||||
{
|
{
|
||||||
print("udp buffer to small. was ");
|
println("Unexpected UDP data packet length - drop packet");
|
||||||
print(maxLen);
|
for (size_t i = 0; i < len; i++)
|
||||||
print(", needed ");
|
_udp.read();
|
||||||
println(len);
|
return 0;
|
||||||
fatalError();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_udp.read(buffer, len);
|
_udp.read(buffer, len);
|
||||||
|
Loading…
Reference in New Issue
Block a user