diff options
author | Ulrich Drepper <drepper@redhat.com> | 2006-04-16 21:34:32 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2006-04-16 21:34:32 +0000 |
commit | 3af48b5b3106e1bb1de4efcabb86cd1fafdff8af (patch) | |
tree | 680c8164581df5834d65b31796392173461d9325 /inet | |
parent | a238728234a94cb8e8024e4718356ff808487a88 (diff) | |
download | glibc-3af48b5b3106e1bb1de4efcabb86cd1fafdff8af.tar glibc-3af48b5b3106e1bb1de4efcabb86cd1fafdff8af.tar.gz glibc-3af48b5b3106e1bb1de4efcabb86cd1fafdff8af.tar.bz2 glibc-3af48b5b3106e1bb1de4efcabb86cd1fafdff8af.zip |
* 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.
Diffstat (limited to 'inet')
-rw-r--r-- | inet/check_pf.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/inet/check_pf.c b/inet/check_pf.c index 5d98c98aff..b015432659 100644 --- a/inet/check_pf.c +++ b/inet/check_pf.c @@ -1,5 +1,5 @@ /* Determine protocol families for which interfaces exist. Generic version. - Copyright (C) 2003 Free Software Foundation, Inc. + Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -23,8 +23,14 @@ void attribute_hidden -__check_pf (bool *seen_ipv4, bool *seen_ipv6) +__check_pf (bool *seen_ipv4, bool *seen_ipv6, + struct in6addrinfo **in6ai, size_t *in6ailen) { + /* By default we have no way to determine information about + deprecated and temporary addresses. */ + *in6ai = NULL; + *in6ailen = 0; + /* Get the interface list via getifaddrs. */ struct ifaddrs *ifa = NULL; if (getifaddrs (&ifa) != 0) |