summaryrefslogtreecommitdiffstats
path: root/sys/netinet/in.c
diff options
context:
space:
mode:
authorume <ume@FreeBSD.org>2001-06-11 12:39:29 +0000
committerume <ume@FreeBSD.org>2001-06-11 12:39:29 +0000
commit832f8d224926758a9ae0b23a6b45353e44fbc87a (patch)
treea79fc7ad2b97862c4a404f352f0211ad93a7b5f1 /sys/netinet/in.c
parent2693854b01a52b0395a91322aa3edf926bddff38 (diff)
downloadFreeBSD-src-832f8d224926758a9ae0b23a6b45353e44fbc87a.zip
FreeBSD-src-832f8d224926758a9ae0b23a6b45353e44fbc87a.tar.gz
Sync with recent KAME.
This work was based on kame-20010528-freebsd43-snap.tgz and some critical problem after the snap was out were fixed. There are many many changes since last KAME merge. TODO: - The definitions of SADB_* in sys/net/pfkeyv2.h are still different from RFC2407/IANA assignment because of binary compatibility issue. It should be fixed under 5-CURRENT. - ip6po_m member of struct ip6_pktopts is no longer used. But, it is still there because of binary compatibility issue. It should be removed under 5-CURRENT. Reviewed by: itojun Obtained from: KAME MFC after: 3 weeks
Diffstat (limited to 'sys/netinet/in.c')
-rw-r--r--sys/netinet/in.c23
1 files changed, 3 insertions, 20 deletions
diff --git a/sys/netinet/in.c b/sys/netinet/in.c
index 95abe3f..170a343 100644
--- a/sys/netinet/in.c
+++ b/sys/netinet/in.c
@@ -51,11 +51,6 @@
#include <netinet/igmp_var.h>
-#include "gif.h"
-#if NGIF > 0
-#include <net/if_gif.h>
-#endif
-
static MALLOC_DEFINE(M_IPMADDR, "in_multi", "internet multicast address");
static int in_mask2len __P((struct in_addr *));
@@ -200,21 +195,6 @@ in_control(so, cmd, data, ifp, p)
int error, hostIsNew, maskIsNew, s;
u_long i;
-#if NGIF > 0
- if (ifp && ifp->if_type == IFT_GIF) {
- switch (cmd) {
- case SIOCSIFPHYADDR:
- case SIOCDIFPHYADDR:
- if (p &&
- (error = suser(p)) != 0)
- return(error);
- case SIOCGIFPSRCADDR:
- case SIOCGIFPDSTADDR:
- return gif_ioctl(ifp, cmd, data);
- }
- }
-#endif
-
switch (cmd) {
case SIOCALIFADDR:
case SIOCDLIFADDR:
@@ -713,6 +693,9 @@ in_ifinit(ifp, ia, sin, scrub)
}
if ((error = rtinit(&(ia->ia_ifa), (int)RTM_ADD, flags)) == 0)
ia->ia_flags |= IFA_ROUTE;
+ /* XXX check if the subnet route points to the same interface */
+ if (error == EEXIST)
+ error = 0;
/*
* If the interface supports multicast, join the "all hosts"
OpenPOWER on IntegriCloud