fixes and better #ifdef's
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@3477 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -40,9 +40,6 @@
|
|||||||
|
|
||||||
RCSID("$Id$");
|
RCSID("$Id$");
|
||||||
|
|
||||||
#if defined(HAVE_SYS_IOCTL_H) && SunOS != 4
|
|
||||||
#include <sys/ioctl.h>
|
|
||||||
#endif
|
|
||||||
#ifdef __osf__
|
#ifdef __osf__
|
||||||
/* hate */
|
/* hate */
|
||||||
struct rtentry;
|
struct rtentry;
|
||||||
@@ -194,19 +191,16 @@ find_all_addresses (krb5_addresses *res, int loop,
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
#endif /* AF_INET */
|
#endif /* AF_INET */
|
||||||
#if defined(AF_INET6) && defined(HAVE_NETINET_IN6_H)
|
#if defined(AF_INET6) && defined(HAVE_SOCKADDR_IN6)
|
||||||
case AF_INET6: {
|
case AF_INET6: {
|
||||||
struct in6_addr *sin6;
|
struct in6_addr *sin6;
|
||||||
|
|
||||||
sin6 = &((struct sockaddr_in6 *)(&ifr->ifr_addr))->sin6_addr;
|
sin6 = &((struct sockaddr_in6 *)(&ifr->ifr_addr))->sin6_addr;
|
||||||
|
|
||||||
if (IN6_LOOPBACK(*sin6) || IN6_LINK_LOCAL(*sin6)) {
|
if (IN6_IS_ADDR_LOOPBACK(sin6)
|
||||||
|
|| IN6_IS_ADDR_LINKLOCAL(sin6)
|
||||||
|
|| IN6_IS_ADDR_V4COMPAT(sin6)) {
|
||||||
break;
|
break;
|
||||||
} else if (IN6_IN4COMPAT(*sin6)) {
|
|
||||||
res->val[j].addr_type = AF_INET;
|
|
||||||
ret = krb5_data_copy(&res->val[j].address,
|
|
||||||
&IN6_IN4ADDR(*sin6),
|
|
||||||
sizeof(struct in_addr));
|
|
||||||
} else {
|
} else {
|
||||||
res->val[j].addr_type = AF_INET6;
|
res->val[j].addr_type = AF_INET6;
|
||||||
ret = krb5_data_copy(&res->val[j].address,
|
ret = krb5_data_copy(&res->val[j].address,
|
||||||
|
Reference in New Issue
Block a user