mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2025-01-14 00:54:18 +00:00
Fix compile error in ip6_frag.c
../../../../lwip/src/core/ipv6/ip6_frag.c: In function ‘ip6_reass’: ../../../../lwip/src/core/ipv6/ip6_frag.c:567:7: error: ISO C90 forbids mixed declarations and code [-Werror=pedantic]
This commit is contained in:
parent
92511f4711
commit
1d7f375992
@ -559,12 +559,13 @@ ip6_reass(struct pbuf *p)
|
||||
|
||||
#if IPV6_FRAG_COPYHEADER
|
||||
if (IPV6_FRAG_REQROOM > 0) {
|
||||
u8_t hdrerr;
|
||||
/* Restore (only) the bytes that we overwrote beyond the fragment header.
|
||||
* Those bytes may belong to either the IPv6 header or an extension
|
||||
* header placed before the fragment header. */
|
||||
MEMCPY(p->payload, ipr->orig_hdr, IPV6_FRAG_REQROOM);
|
||||
/* get back room for struct ip6_reass_helper (only required if sizeof(void*) > 4) */
|
||||
u8_t hdrerr = pbuf_header(p, -(s16_t)(IPV6_FRAG_REQROOM));
|
||||
hdrerr = pbuf_header(p, -(s16_t)(IPV6_FRAG_REQROOM));
|
||||
LWIP_UNUSED_ARG(hdrerr); /* in case of LWIP_NOASSERT */
|
||||
LWIP_ASSERT("no room for struct ip6_reass_helper", hdrerr == 0);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user