mirror of
https://git.savannah.nongnu.org/git/lwip.git
synced 2026-05-17 21:56:45 +08:00
work on -Wconversion...
This commit is contained in:
@@ -116,7 +116,7 @@ struct ip_globals
|
||||
#endif /* LWIP_IPV4 */
|
||||
#if LWIP_IPV6
|
||||
/** Header of the input IPv6 packet currently being processed. */
|
||||
struct ip6_hdr *current_ip6_header;
|
||||
const struct ip6_hdr *current_ip6_header;
|
||||
#endif /* LWIP_IPV6 */
|
||||
/** Total header length of current_ip4/6_header (i.e. after this, the UDP/TCP header starts) */
|
||||
u16_t current_ip_header_tot_len;
|
||||
@@ -152,7 +152,7 @@ extern struct ip_globals ip_data;
|
||||
/** Get the IPv6 header of the current packet.
|
||||
* This function must only be called from a receive callback (udp_recv,
|
||||
* raw_recv, tcp_accept). It will return NULL otherwise. */
|
||||
#define ip6_current_header() ((const struct ip6_hdr*)(ip_data.current_ip6_header))
|
||||
#define ip6_current_header() ip_data.current_ip6_header
|
||||
/** Returns TRUE if the current IP input packet is IPv6, FALSE if it is IPv4 */
|
||||
#define ip_current_is_v6() (ip6_current_header() != NULL)
|
||||
/** Source IPv6 address of current_header */
|
||||
@@ -194,7 +194,7 @@ extern struct ip_globals ip_data;
|
||||
/** Get the IPv6 header of the current packet.
|
||||
* This function must only be called from a receive callback (udp_recv,
|
||||
* raw_recv, tcp_accept). It will return NULL otherwise. */
|
||||
#define ip6_current_header() ((const struct ip6_hdr*)(ip_data.current_ip6_header))
|
||||
#define ip6_current_header() ip_data.current_ip6_header
|
||||
/** Always returns TRUE when only supporting IPv6 only */
|
||||
#define ip_current_is_v6() 1
|
||||
/** Get the transport layer protocol */
|
||||
|
||||
@@ -90,7 +90,7 @@ extern "C" {
|
||||
struct ip6_reassdata {
|
||||
struct ip6_reassdata *next;
|
||||
struct pbuf *p;
|
||||
struct ip6_hdr *iphdr; /* pointer to the first (original) IPv6 header */
|
||||
const struct ip6_hdr *iphdr; /* pointer to the first (original) IPv6 header */
|
||||
#if IPV6_FRAG_COPYHEADER
|
||||
ip6_addr_p_t src; /* copy of the source address in the IP header */
|
||||
ip6_addr_p_t dest; /* copy of the destination address in the IP header */
|
||||
|
||||
Reference in New Issue
Block a user