Redesign struct hostapd_ip_addr to be of fixed size

This structure is embedded in some other structures and as such, it
would be nicer if this would not change its length based on build
options.
This commit is contained in:
Jouni Malinen 2009-12-24 12:26:47 +02:00
parent f42cdcc894
commit 6aa9e7a64a

View file

@ -16,13 +16,14 @@
#define IP_ADDR_H
struct hostapd_ip_addr {
int af; /* AF_INET / AF_INET6 */
union {
struct in_addr v4;
#ifdef CONFIG_IPV6
struct in6_addr v6;
#endif /* CONFIG_IPV6 */
u8 max_len[16];
} u;
int af; /* AF_INET / AF_INET6 */
};
const char * hostapd_ip_txt(const struct hostapd_ip_addr *addr, char *buf,