diff --git a/src/mac/LoRaMac.c b/src/mac/LoRaMac.c index 8d42fbb88..31e8f3afc 100644 --- a/src/mac/LoRaMac.c +++ b/src/mac/LoRaMac.c @@ -938,6 +938,14 @@ static void ProcessRadioRxDone( void ) } } + // Abort on empty radio frames + if( size == 0 ) + { + MacCtx.McpsIndication.Status = LORAMAC_EVENT_INFO_STATUS_ERROR; + PrepareRxDoneAbort( ); + return; + } + macHdr.Value = payload[pktHeaderLen++]; // Accept frames of LoRaWAN Major Version 1 only