Disconnect hostapd from building in base
[dragonfly.git] / contrib / hostapd / src / utils / ip_addr.h
CommitLineData
ebfa2275 1/*
a875087d
JL
2 * IP address processing
3 * Copyright (c) 2003-2006, Jouni Malinen <j@w1.fi>
ebfa2275 4 *
4781064b
JM
5 * This software may be distributed under the terms of the BSD license.
6 * See README for more details.
ebfa2275
SZ
7 */
8
a875087d
JL
9#ifndef IP_ADDR_H
10#define IP_ADDR_H
ebfa2275
SZ
11
12struct hostapd_ip_addr {
4781064b 13 int af; /* AF_INET / AF_INET6 */
ebfa2275
SZ
14 union {
15 struct in_addr v4;
16#ifdef CONFIG_IPV6
17 struct in6_addr v6;
18#endif /* CONFIG_IPV6 */
4781064b 19 u8 max_len[16];
ebfa2275 20 } u;
ebfa2275
SZ
21};
22
a875087d
JL
23const char * hostapd_ip_txt(const struct hostapd_ip_addr *addr, char *buf,
24 size_t buflen);
25int hostapd_ip_diff(struct hostapd_ip_addr *a, struct hostapd_ip_addr *b);
26int hostapd_parse_ip_addr(const char *txt, struct hostapd_ip_addr *addr);
27
28#endif /* IP_ADDR_H */