diff options
author | 2008-07-13 20:41:39 +0000 | |
---|---|---|
committer | 2008-07-13 20:41:39 +0000 | |
commit | 521d286cc65a5b72e7f0471c896ce785514d1c64 (patch) | |
tree | c1a11af1da2c4f63738c17bdaa0c4aa8bca4879e | |
parent | core(4) (diff) | |
download | wireguard-openbsd-521d286cc65a5b72e7f0471c896ce785514d1c64.tar.xz wireguard-openbsd-521d286cc65a5b72e7f0471c896ce785514d1c64.zip |
Do not specify the gateway on RTM_DELETE -- similar fix was done in the arp
code. This fixes in6_ifloop_request warnings seen on carp interfaces.
OK henning@, found and tested by david@
-rw-r--r-- | sys/netinet6/in6.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/netinet6/in6.c b/sys/netinet6/in6.c index 6c57d476969..e4f200b54a3 100644 --- a/sys/netinet6/in6.c +++ b/sys/netinet6/in6.c @@ -1,4 +1,4 @@ -/* $OpenBSD: in6.c,v 1.77 2008/06/11 19:00:50 mcbride Exp $ */ +/* $OpenBSD: in6.c,v 1.78 2008/07/13 20:41:39 claudio Exp $ */ /* $KAME: in6.c,v 1.372 2004/06/14 08:14:21 itojun Exp $ */ /* @@ -166,7 +166,8 @@ in6_ifloop_request(int cmd, struct ifaddr *ifa) bzero(&info, sizeof(info)); info.rti_flags = RTF_UP | RTF_HOST | RTF_LLINFO; info.rti_info[RTAX_DST] = ifa->ifa_addr; - info.rti_info[RTAX_GATEWAY] = ifa->ifa_addr; + if (cmd != RTM_DELETE) + info.rti_info[RTAX_GATEWAY] = ifa->ifa_addr; info.rti_info[RTAX_NETMASK] = (struct sockaddr *)&all1_sa; e = rtrequest1(cmd, &info, RTP_CONNECTED, &nrt, 0); if (e != 0) { |