Просмотр исходного кода

openthread_port: fix receive buffer overflow

zhangwenxu 3 лет назад
Родитель
Сommit
eabc5e5b01
1 измененных файлов с 1 добавлено и 0 удалено
  1. 1 0
      components/openthread/port/esp_openthread_radio.c

+ 1 - 0
components/openthread/port/esp_openthread_radio.c

@@ -422,6 +422,7 @@ void IRAM_ATTR esp_ieee802154_receive_done(uint8_t *data, esp_ieee802154_frame_i
 {
 {
     if (s_recv_queue.used == CONFIG_IEEE802154_RX_BUFFER_SIZE) {
     if (s_recv_queue.used == CONFIG_IEEE802154_RX_BUFFER_SIZE) {
         ESP_EARLY_LOGE(OT_PLAT_LOG_TAG, "radio receive buffer full!");
         ESP_EARLY_LOGE(OT_PLAT_LOG_TAG, "radio receive buffer full!");
+        return;
     }
     }
 
 
     s_rssi = frame_info->rssi;
     s_rssi = frame_info->rssi;