From 2b3db52c704dcbd5fa24adb5eea77d9b8d7da394 Mon Sep 17 00:00:00 2001 From: Dirk Ziegelmeier Date: Sat, 12 Mar 2016 12:26:23 +0100 Subject: [PATCH] pppol2tp.c: Avoid an #ifdef - there is a new UDP API function that can be used here --- src/netif/ppp/pppol2tp.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/netif/ppp/pppol2tp.c b/src/netif/ppp/pppol2tp.c index 752fde73..99b4e5fd 100644 --- a/src/netif/ppp/pppol2tp.c +++ b/src/netif/ppp/pppol2tp.c @@ -129,12 +129,7 @@ ppp_pcb *pppol2tp_create(struct netif *pppif, goto memp_malloc_l2tp_failed; } -#if LWIP_IPV6 - if (IP_IS_V6_VAL(*ipaddr)) { - udp = udp_new_ip_type(IPADDR_TYPE_V6); - } else -#endif /* LWIP_IPV6 */ - udp = udp_new(); + udp = udp_new_ip_type(IP_GET_TYPE(ipaddr)); if (udp == NULL) { goto udp_new_failed; }