From ac151e05e77128ff6ee992d9f4b084361dad7d98 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Tue, 27 Aug 2019 16:20:39 -0600 Subject: [PATCH] Fix warnings found in build testing. --- arch/arm/src/imxrt/Kconfig | 8 ++++---- net/tcp/tcp_send.c | 12 +----------- 2 files changed, 5 insertions(+), 15 deletions(-) diff --git a/arch/arm/src/imxrt/Kconfig b/arch/arm/src/imxrt/Kconfig index b74d8391be..0983af260e 100644 --- a/arch/arm/src/imxrt/Kconfig +++ b/arch/arm/src/imxrt/Kconfig @@ -449,7 +449,7 @@ config ENC1_MOD if ENC1_MOD config ENC1_MODULUS - int "Modulus to wrap around" + hex "Modulus to wrap around" default 0xffffffff endif # ENC1_MOD @@ -524,7 +524,7 @@ config ENC2_MOD if ENC2_MOD config ENC2_MODULUS - int "Modulus to wrap around" + hex "Modulus to wrap around" default 0xffffffff endif # ENC2_MOD @@ -601,7 +601,7 @@ config ENC3_MOD if ENC3_MOD config ENC3_MODULUS - int "Modulus to wrap around" + hex "Modulus to wrap around" default 0xffffffff endif # ENC3_MOD @@ -676,7 +676,7 @@ config ENC4_MOD if ENC4_MOD config ENC4_MODULUS - int "Modulus to wrap around" + hex "Modulus to wrap around" default 0xffffffff endif # ENC4_MOD diff --git a/net/tcp/tcp_send.c b/net/tcp/tcp_send.c index 59db5cee26..a5ffd198d2 100644 --- a/net/tcp/tcp_send.c +++ b/net/tcp/tcp_send.c @@ -432,16 +432,6 @@ void tcp_reset(FAR struct net_driver_s *dev) uint16_t tmp16; uint16_t acklen = 0; uint8_t seqbyte; - uint8_t domain; - -#if defined(CONFIG_NET_IPv4) && defined(CONFIG_NET_IPv6) - bool ipv6 = IFF_IS_IPv6(dev->d_flags); - domain = ipv6 ? PF_INET6 : PF_INET; -#elif defined(CONFIG_NET_IPv4) - domain = PF_INET; -#else /* defined(CONFIG_NET_IPv6) */ - domain = PF_INET6; -#endif #ifdef CONFIG_NET_STATISTICS g_netstats.tcp.rst++; @@ -456,7 +446,7 @@ void tcp_reset(FAR struct net_driver_s *dev) #ifdef CONFIG_NET_IPv6 #ifdef CONFIG_NET_IPv4 - if (ipv6) + if (IFF_IS_IPv6(dev->d_flags)) #endif { FAR struct ipv6_hdr_s *ip = IPv6BUF;