mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-08-23 22:56:00 +00:00
This fixes the following warnings: test_tcp.c:266:5: error: code will never be executed [-Werror,-Wunreachable-code] pbuf_free(p); ^~~~~~~~~ - The check API 'fail' aborts the test, thus pbuf_free(p) will never be executed pbuf.c:783:111: error: format specifies type 'unsigned short' but the argument has type 'u8_t' (aka 'unsigned char') [-Werror,-Wformat] LWIP_DEBUGF( PBUF_DEBUG | LWIP_DBG_TRACE, ("pbuf_free: %p has ref %"U16_F", ending here.\n", (void *)p, ref)); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~ - LWIP_PBUF_REF_T is u8_t by default and doesn't match U16_F, so cast to u16_t. The cast and formatter will need to be changed if ref is larger than 16 bits ethernet.c:105:16: error: format specifies type 'unsigned char' but the argument has type 'unsigned int' [-Werror,-Wformat] (unsigned)ethhdr->dest.addr[0], (unsigned)ethhdr->dest.addr[1], (unsigned)ethhdr->dest.addr[2], ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - addr[] is type u8_t, formatter is X8_F which should be 8 bits. 'unsigned' is an int, so cast to unsighed char instead |
||
---|---|---|
.. | ||
api | ||
arch | ||
core | ||
dhcp | ||
etharp | ||
ip4 | ||
mdns | ||
mqtt | ||
tcp | ||
udp | ||
Filelists.mk | ||
lwip_check.h | ||
lwip_unittests.c | ||
lwipopts.h |