From 8c5ae6d2660a5690b8da16cc0fca7352fb510e1b Mon Sep 17 00:00:00 2001 From: jgromes Date: Sun, 14 Jan 2024 18:25:51 +0100 Subject: [PATCH] [LoRaWAN] Remove variable length array (CI_BUILD_ALL) --- src/protocols/LoRaWAN/LoRaWAN.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/protocols/LoRaWAN/LoRaWAN.cpp b/src/protocols/LoRaWAN/LoRaWAN.cpp index 54c36b197..931f3bdde 100644 --- a/src/protocols/LoRaWAN/LoRaWAN.cpp +++ b/src/protocols/LoRaWAN/LoRaWAN.cpp @@ -1417,7 +1417,7 @@ int16_t LoRaWANNode::downlink(uint8_t* data, size_t* len, LoRaWANEvent_t* event) // process FOpts (if there are any) if(foptsLen > 0) { // there are some Fopts, decrypt them - uint8_t fopts[RADIOLIB_MAX(RADIOLIB_LORAWAN_FHDR_FOPTS_LEN_MASK, (int)foptsLen)]; + uint8_t fopts[RADIOLIB_LORAWAN_FHDR_FOPTS_LEN_MASK]; // TODO it COULD be the case that the assumed FCnt rollover is incorrect, if possible figure out a way to catch this and retry with just fcnt16 // if there are <= 15 bytes of FOpts, they are in the FHDR, otherwise they are in the payload