summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 135fcb2)
raw | patch | inline | side by side (parent: 135fcb2)
author | Florian Forster <octo@huhu.verplant.org> | |
Fri, 7 Jan 2011 07:28:32 +0000 (08:28 +0100) | ||
committer | Florian Forster <octo@huhu.verplant.org> | |
Fri, 7 Jan 2011 07:28:32 +0000 (08:28 +0100) |
src/utils_dns.c | patch | blob | history |
diff --git a/src/utils_dns.c b/src/utils_dns.c
index 22c9b95994377f9ed1752d4192eb25c29a97b8e8..d1c8d5d504a73b0b8f1ad6b603b16eb69ba81db6 100644 (file)
--- a/src/utils_dns.c
+++ b/src/utils_dns.c
return 1;
}
+#if HAVE_NETINET_IP6_H
static int
handle_ipv6 (struct ip6_hdr *ipv6, int len)
{
return (1); /* Success */
} /* int handle_ipv6 */
+/* #endif HAVE_NETINET_IP6_H */
+
+#else /* if !HAVE_NETINET_IP6_H */
+static int
+handle_ipv6 (__attribute__((unused)) void *pkg,
+ __attribute__((unused)) int len)
+{
+ return (0);
+}
+#endif /* !HAVE_NETINET_IP6_H */
static int
handle_ip(const struct ip *ip, int len)
struct in6_addr d_addr;
if (ip->ip_v == 6)
- return (handle_ipv6 ((struct ip6_hdr *) ip, len));
+ return (handle_ipv6 ((void *) ip, len));
in6_addr_from_buffer (&s_addr, &ip->ip_src.s_addr, sizeof (ip->ip_src.s_addr), AF_INET);
in6_addr_from_buffer (&d_addr, &ip->ip_dst.s_addr, sizeof (ip->ip_dst.s_addr), AF_INET);
return 0;
memcpy(buf, pkt, len);
if (ETHERTYPE_IPV6 == etype)
- return (handle_ipv6 ((struct ip6_hdr *) buf, len));
+ return (handle_ipv6 ((void *) buf, len));
else
return handle_ip((struct ip *) buf, len);
}
return 0;
if (ETHERTYPE_IPV6 == etype)
- return (handle_ipv6 ((struct ip6_hdr *) pkt, len));
+ return (handle_ipv6 ((void *) pkt, len));
else
return handle_ip((struct ip *) pkt, len);
}