From 8979d70a694f852c779b02a087962771cacae53e Mon Sep 17 00:00:00 2001 From: Urey <29945179@qq.com> Date: Fri, 23 Sep 2016 17:00:31 +0800 Subject: Update ethernetif.c if device->eth_rx is NULL ,rx thread will hard fault... --- components/net/lwip-1.4.1/src/netif/ethernetif.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'components/net') diff --git a/components/net/lwip-1.4.1/src/netif/ethernetif.c b/components/net/lwip-1.4.1/src/netif/ethernetif.c index f0b2f814dc..f0c28ecf06 100644 --- a/components/net/lwip-1.4.1/src/netif/ethernetif.c +++ b/components/net/lwip-1.4.1/src/netif/ethernetif.c @@ -367,6 +367,8 @@ static void eth_rx_thread_entry(void* parameter) /* receive all of buffer */ while (1) { + if(device->eth_rx == RT_NULL) break; + p = device->eth_rx(&(device->parent)); if (p != RT_NULL) { -- cgit v1.3.1