From 3af48b5b3106e1bb1de4efcabb86cd1fafdff8af Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Sun, 16 Apr 2006 21:34:32 +0000 Subject: * include/ifaddrs.h: Define struct in6addrinfo. Add two more parameters to __check_pf. * sysdeps/unix/sysv/linux/check_pf.c: When using the netlink interface, determine whether IPv6 addresses are deprecated or temporary. Create array of those addresses. * inet/check_pf.c: Always tell caller there are no depracated and temporary addresses. * sysdeps/posix/getaddrinfo.c: Pretty printing. (struct sort_result): Add source_addr_flags field. (rfc3484_sort): Implement rule 3 and 7. (in6aicmp): New function. (getaddrinfo): Call __check_pf also when we need info about IPv6 source addresses. When creating array for sorting addresses, look up deprecated and temporary addresses returned by __check_pf and add flag if necessary. --- include/ifaddrs.h | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/ifaddrs.h b/include/ifaddrs.h index aa20c35..d41547a 100644 --- a/include/ifaddrs.h +++ b/include/ifaddrs.h @@ -5,6 +5,17 @@ libc_hidden_proto (getifaddrs) libc_hidden_proto (freeifaddrs) -extern void __check_pf (bool *seen_ipv4, bool *seen_ipv6) attribute_hidden; +struct in6addrinfo +{ + enum { + in6ai_deprecated = 1, + in6ai_temporary = 2 + } flags; + uint32_t addr[4]; +}; + +extern void __check_pf (bool *seen_ipv4, bool *seen_ipv6, + struct in6addrinfo **in6ai, size_t *in6ailen) + attribute_hidden; #endif /* ifaddrs.h */ -- cgit v1.1