diff options
| author | liuxianliang <[email protected]> | 2021-12-06 10:27:54 +0800 |
|---|---|---|
| committer | liuxianliang <[email protected]> | 2021-12-06 10:27:54 +0800 |
| commit | 9b1f7c4ffe04f158c0019e3645cd5a0551dbd421 (patch) | |
| tree | 9ea333cdce9b80fb8cb1436dde9b2532c08da715 /components | |
| parent | 3dd1aa754c0ca9e8c5df0d3b3c98942d115149b1 (diff) | |
[fix] the problem of implicit declaration for "lwip_ip4_route_src".
Diffstat (limited to 'components')
| -rw-r--r-- | components/net/lwip-2.1.2/src/arch/sys_arch.c | 2 | ||||
| -rw-r--r-- | components/net/lwip-2.1.2/src/lwipopts.h | 3 |
2 files changed, 5 insertions, 0 deletions
diff --git a/components/net/lwip-2.1.2/src/arch/sys_arch.c b/components/net/lwip-2.1.2/src/arch/sys_arch.c index 0631a68369..a7d3f98968 100644 --- a/components/net/lwip-2.1.2/src/arch/sys_arch.c +++ b/components/net/lwip-2.1.2/src/arch/sys_arch.c @@ -779,6 +779,7 @@ void ppp_trace(int level, const char *format, ...) } #endif +#ifdef LWIP_HOOK_IP4_ROUTE_SRC struct netif *lwip_ip4_route_src(const ip4_addr_t *dest, const ip4_addr_t *src) { struct netif *netif; @@ -802,6 +803,7 @@ struct netif *lwip_ip4_route_src(const ip4_addr_t *dest, const ip4_addr_t *src) netif = netif_default; return netif; } +#endif /* LWIP_HOOK_IP4_ROUTE_SRC */ /* * export bsd socket symbol for RT-Thread Application Module diff --git a/components/net/lwip-2.1.2/src/lwipopts.h b/components/net/lwip-2.1.2/src/lwipopts.h index 862e3b6eaa..f5eb177d5d 100644 --- a/components/net/lwip-2.1.2/src/lwipopts.h +++ b/components/net/lwip-2.1.2/src/lwipopts.h @@ -645,4 +645,7 @@ #define LWIP_HOOK_IP4_ROUTE_SRC(dest, src) lwip_ip4_route_src(dest, src) +#include "lwip/ip_addr.h" +struct netif *lwip_ip4_route_src(const ip4_addr_t *dest, const ip4_addr_t *src); + #endif /* __LWIPOPTS_H__ */ |
