Cast the addresses when copying IPv4 and IPv6 addresses using the IPv4 and IPv6 copy macros.

This commit is contained in:
Adam Dunkels 2015-03-24 22:28:29 +01:00
parent c06e6ae74d
commit daef1ea252

View file

@ -1030,10 +1030,10 @@ struct uip_udp_conn *uip_udp_new(const uip_ipaddr_t *ripaddr, uint16_t rport);
#define uip_ipaddr_copy(dest, src) (*(dest) = *(src)) #define uip_ipaddr_copy(dest, src) (*(dest) = *(src))
#endif #endif
#ifndef uip_ip4addr_copy #ifndef uip_ip4addr_copy
#define uip_ip4addr_copy(dest, src) (*(dest) = *(src)) #define uip_ip4addr_copy(dest, src) (*((uip_ip4addr_t *)dest) = *((uip_ip4addr_t *)src))
#endif #endif
#ifndef uip_ip6addr_copy #ifndef uip_ip6addr_copy
#define uip_ip6addr_copy(dest, src) (*(dest) = *(src)) #define uip_ip6addr_copy(dest, src) (*((uip_ip6addr_t *)dest) = *((uip_ip6addr_t *)src))
#endif #endif
/** /**