Skip to content
Snippets Groups Projects
Commit 78e0aa2a authored by Gunar Schorcht's avatar Gunar Schorcht Committed by Schorcht
Browse files

cpu/esp8266: usage of _esp_wifi_recv_cb

Overriding ethernet_input function _esp_wifi_recv_cb is only used when the WiFi interface is in connected state.
parent c5a9058a
No related branches found
No related tags found
No related merge requests found
......@@ -514,7 +514,12 @@ extern err_t __real_ethernet_input(struct pbuf *pb, struct netif* netif);
err_t __wrap_ethernet_input(struct pbuf *pb, struct netif* netif)
{
ESP_WIFI_DEBUG("%p %p", pb, netif);
_esp_wifi_recv_cb(pb, netif);
if (_esp_wifi_dev.state == ESP_WIFI_CONNECTED) {
_esp_wifi_recv_cb(pb, netif);
}
else {
__real_ethernet_input(pb, netif);
}
return ERR_OK;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment