mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-08-25 07:33:11 +00:00
Apply patch from Derek Pravala: Fix segfault in ip6_route when there is no default netif
This commit is contained in:
parent
eead3a7038
commit
5358380c5f
@ -184,7 +184,7 @@ ip6_route(const ip6_addr_t *src, const ip6_addr_t *dest)
|
|||||||
#endif /* LWIP_NETIF_LOOPBACK && !LWIP_HAVE_LOOPIF */
|
#endif /* LWIP_NETIF_LOOPBACK && !LWIP_HAVE_LOOPIF */
|
||||||
|
|
||||||
/* no matching netif found, use default netif, if up */
|
/* no matching netif found, use default netif, if up */
|
||||||
if (!netif_is_up(netif_default) || !netif_is_link_up(netif_default)) {
|
if ((netif_default == NULL) || !netif_is_up(netif_default) || !netif_is_link_up(netif_default)) {
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
return netif_default;
|
return netif_default;
|
||||||
|
Loading…
Reference in New Issue
Block a user