(ipv4_uninteresting): ignore 0.0.0.0 (INADDR_ANY)
(ipv6_uninteresting): remove unused macro git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@7424 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -126,6 +126,11 @@ ipv4_h_addr2addr (const char *addr,
|
|||||||
static krb5_boolean
|
static krb5_boolean
|
||||||
ipv4_uninteresting (const struct sockaddr *sa)
|
ipv4_uninteresting (const struct sockaddr *sa)
|
||||||
{
|
{
|
||||||
|
const struct sockaddr_in *sin = (const struct sockaddr_in *)sa;
|
||||||
|
|
||||||
|
if (sin->sin_addr.s_addr == INADDR_ANY)
|
||||||
|
return TRUE;
|
||||||
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -270,10 +275,6 @@ ipv6_h_addr2addr (const char *addr,
|
|||||||
static krb5_boolean
|
static krb5_boolean
|
||||||
ipv6_uninteresting (const struct sockaddr *sa)
|
ipv6_uninteresting (const struct sockaddr *sa)
|
||||||
{
|
{
|
||||||
#ifndef IN6_IS_ADDR_LOOPBACK
|
|
||||||
#define IN6_IS_ADDR_LOOPBACK(x) IN6_IS_LOOPBACK(*x)
|
|
||||||
#endif
|
|
||||||
|
|
||||||
const struct sockaddr_in6 *sin6 = (const struct sockaddr_in6 *)sa;
|
const struct sockaddr_in6 *sin6 = (const struct sockaddr_in6 *)sa;
|
||||||
const struct in6_addr *in6 = (const struct in6_addr *)&sin6->sin6_addr;
|
const struct in6_addr *in6 = (const struct in6_addr *)&sin6->sin6_addr;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user