Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/netinet6 Use satosin6 instead of its own macro
details: https://anonhg.NetBSD.org/src/rev/dbf1db67a3a6
branches: trunk
changeset: 340840:dbf1db67a3a6
user: ozaki-r <ozaki-r%NetBSD.org@localhost>
date: Mon Oct 05 04:15:42 2015 +0000
description:
Use satosin6 instead of its own macro
diffstat:
sys/netinet6/nd6_rtr.c | 8 +++-----
1 files changed, 3 insertions(+), 5 deletions(-)
diffs (41 lines):
diff -r 541a58c3dd88 -r dbf1db67a3a6 sys/netinet6/nd6_rtr.c
--- a/sys/netinet6/nd6_rtr.c Sun Oct 04 23:25:32 2015 +0000
+++ b/sys/netinet6/nd6_rtr.c Mon Oct 05 04:15:42 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: nd6_rtr.c,v 1.103 2015/08/24 09:45:29 ozaki-r Exp $ */
+/* $NetBSD: nd6_rtr.c,v 1.104 2015/10/05 04:15:42 ozaki-r Exp $ */
/* $KAME: nd6_rtr.c,v 1.95 2001/02/07 08:09:47 itojun Exp $ */
/*
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: nd6_rtr.c,v 1.103 2015/08/24 09:45:29 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: nd6_rtr.c,v 1.104 2015/10/05 04:15:42 ozaki-r Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -2097,13 +2097,12 @@
static int
rt6_deleteroute(struct rtentry *rt, void *arg)
{
-#define SIN6(s) ((struct sockaddr_in6 *)s)
struct in6_addr *gate = (struct in6_addr *)arg;
if (rt->rt_gateway == NULL || rt->rt_gateway->sa_family != AF_INET6)
return (0);
- if (!IN6_ARE_ADDR_EQUAL(gate, &SIN6(rt->rt_gateway)->sin6_addr))
+ if (!IN6_ARE_ADDR_EQUAL(gate, &satosin6(rt->rt_gateway)->sin6_addr))
return (0);
/*
@@ -2123,7 +2122,6 @@
return (rtrequest(RTM_DELETE, rt_getkey(rt), rt->rt_gateway,
rt_mask(rt), rt->rt_flags, NULL));
-#undef SIN6
}
int
Home |
Main Index |
Thread Index |
Old Index