mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-12-24 15:14:06 +00:00
test_tcp: remove unnecessary memsets
test_tcp_init_netif() memsets both netif and txcounters, so no need to manually do it
This commit is contained in:
parent
34c9e30225
commit
648b2b6f2b
@ -107,7 +107,6 @@ START_TEST(test_tcp_recv_inseq)
|
||||
LWIP_UNUSED_ARG(_i);
|
||||
|
||||
/* initialize local vars */
|
||||
memset(&netif, 0, sizeof(netif));
|
||||
IP_ADDR4(&local_ip, 192, 168, 1, 1);
|
||||
IP_ADDR4(&remote_ip, 192, 168, 1, 2);
|
||||
IP_ADDR4(&netmask, 255, 255, 255, 0);
|
||||
@ -159,7 +158,6 @@ START_TEST(test_tcp_malformed_header)
|
||||
LWIP_UNUSED_ARG(_i);
|
||||
|
||||
/* initialize local vars */
|
||||
memset(&netif, 0, sizeof(netif));
|
||||
IP_ADDR4(&local_ip, 192, 168, 1, 1);
|
||||
IP_ADDR4(&remote_ip, 192, 168, 1, 2);
|
||||
IP_ADDR4(&netmask, 255, 255, 255, 0);
|
||||
@ -604,7 +602,6 @@ static void test_tcp_tx_full_window_lost(u8_t zero_window_probe_from_unsent)
|
||||
IP_ADDR4(&netmask, 255, 255, 255, 0);
|
||||
test_tcp_init_netif(&netif, &txcounters, &local_ip, &netmask);
|
||||
memset(&counters, 0, sizeof(counters));
|
||||
memset(&txcounters, 0, sizeof(txcounters));
|
||||
|
||||
/* create and initialize the pcb */
|
||||
pcb = test_tcp_new_counters_pcb(&counters);
|
||||
|
@ -166,7 +166,6 @@ START_TEST(test_tcp_recv_ooseq_FIN_OOSEQ)
|
||||
LWIP_UNUSED_ARG(_i);
|
||||
|
||||
/* initialize local vars */
|
||||
memset(&netif, 0, sizeof(netif));
|
||||
IP_ADDR4(&local_ip, 192, 168, 1, 1);
|
||||
IP_ADDR4(&remote_ip, 192, 168, 1, 2);
|
||||
IP_ADDR4(&netmask, 255, 255, 255, 0);
|
||||
@ -308,7 +307,6 @@ START_TEST(test_tcp_recv_ooseq_FIN_INSEQ)
|
||||
LWIP_UNUSED_ARG(_i);
|
||||
|
||||
/* initialize local vars */
|
||||
memset(&netif, 0, sizeof(netif));
|
||||
IP_ADDR4(&local_ip, 192, 168, 1, 1);
|
||||
IP_ADDR4(&remote_ip, 192, 168, 1, 2);
|
||||
IP_ADDR4(&netmask, 255, 255, 255, 0);
|
||||
@ -485,7 +483,6 @@ START_TEST(test_tcp_recv_ooseq_overrun_rxwin)
|
||||
}
|
||||
|
||||
/* initialize local vars */
|
||||
memset(&netif, 0, sizeof(netif));
|
||||
IP_ADDR4(&local_ip, 192, 168, 1, 1);
|
||||
IP_ADDR4(&remote_ip, 192, 168, 1, 2);
|
||||
IP_ADDR4(&netmask, 255, 255, 255, 0);
|
||||
@ -578,7 +575,6 @@ START_TEST(test_tcp_recv_ooseq_overrun_rxwin_edge)
|
||||
}
|
||||
|
||||
/* initialize local vars */
|
||||
memset(&netif, 0, sizeof(netif));
|
||||
IP_ADDR4(&local_ip, 192, 168, 1, 1);
|
||||
IP_ADDR4(&remote_ip, 192, 168, 1, 2);
|
||||
IP_ADDR4(&netmask, 255, 255, 255, 0);
|
||||
@ -670,7 +666,6 @@ START_TEST(test_tcp_recv_ooseq_max_bytes)
|
||||
}
|
||||
|
||||
/* initialize local vars */
|
||||
memset(&netif, 0, sizeof(netif));
|
||||
IP_ADDR4(&local_ip, 192, 168, 1, 1);
|
||||
IP_ADDR4(&remote_ip, 192, 168, 1, 2);
|
||||
IP_ADDR4(&netmask, 255, 255, 255, 0);
|
||||
@ -751,7 +746,6 @@ START_TEST(test_tcp_recv_ooseq_max_pbufs)
|
||||
}
|
||||
|
||||
/* initialize local vars */
|
||||
memset(&netif, 0, sizeof(netif));
|
||||
IP_ADDR4(&local_ip, 192, 168, 1, 1);
|
||||
IP_ADDR4(&remote_ip, 192, 168, 1, 2);
|
||||
IP_ADDR4(&netmask, 255, 255, 255, 0);
|
||||
@ -854,7 +848,6 @@ static void test_tcp_recv_ooseq_double_FINs(int delay_packet)
|
||||
}
|
||||
|
||||
/* initialize local vars */
|
||||
memset(&netif, 0, sizeof(netif));
|
||||
IP_ADDR4(&local_ip, 192, 168, 1, 1);
|
||||
IP_ADDR4(&remote_ip, 192, 168, 1, 2);
|
||||
IP_ADDR4(&netmask, 255, 255, 255, 0);
|
||||
|
Loading…
Reference in New Issue
Block a user