aboutsummaryrefslogtreecommitdiff
path: root/sys/net/if_loop.c
diff options
context:
space:
mode:
authorJulian Elischer <julian@FreeBSD.org>1998-06-14 20:58:17 +0000
committerJulian Elischer <julian@FreeBSD.org>1998-06-14 20:58:17 +0000
commit201c2527a9624c5f374341262c4318b0d02071c5 (patch)
tree436305de50a68eade35eaaf77925de680ae3da18 /sys/net/if_loop.c
parent679786927141ddfbf62b73a4531ff128aeb869b2 (diff)
downloadsrc-201c2527a9624c5f374341262c4318b0d02071c5.tar.gz
src-201c2527a9624c5f374341262c4318b0d02071c5.zip
Try narrow down the culprit sending undefined packet types through the loopback
Notes
Notes: svn path=/head/; revision=36992
Diffstat (limited to 'sys/net/if_loop.c')
-rw-r--r--sys/net/if_loop.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/sys/net/if_loop.c b/sys/net/if_loop.c
index ee77758535e7..9153923d8f81 100644
--- a/sys/net/if_loop.c
+++ b/sys/net/if_loop.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)if_loop.c 8.1 (Berkeley) 6/10/93
- * $Id: if_loop.c,v 1.33 1998/06/12 03:48:09 julian Exp $
+ * $Id: if_loop.c,v 1.34 1998/06/12 20:03:26 julian Exp $
*/
/*
@@ -144,6 +144,19 @@ looutput(ifp, m, dst, rt)
}
ifp->if_opackets++;
ifp->if_obytes += m->m_pkthdr.len;
+#if 1 /* XXX */
+ switch (dst->sa_family) {
+ case AF_INET:
+ case AF_IPX:
+ case AF_NS:
+ case AF_ISO:
+ case AF_APPLETALK:
+ default:
+ printf("looutput: af=%d unexpected", dst->sa_family);
+ m_freem(m);
+ return (EAFNOSUPPORT);
+ }
+#endif
return(if_simloop(ifp, m, dst, 0));
}