summaryrefslogtreecommitdiff
path: root/sys/dev/ic/elink3.c
diff options
context:
space:
mode:
authorJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2000-02-25 04:26:12 +0000
committerJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2000-02-25 04:26:12 +0000
commit7bfd5fea035a5dc189d0b79dc1258ff137f27a81 (patch)
tree5430160a97536338af0441281c46689d00575d64 /sys/dev/ic/elink3.c
parentbf3a9a1952b5bfe25b1637a3742e275e5f7db164 (diff)
clear m->m_pkthdr when changing mbuf type to M_PKTHDR.
without it, junk pointer in m->m_pkthdr.tdbi may bite us.
Diffstat (limited to 'sys/dev/ic/elink3.c')
-rw-r--r--sys/dev/ic/elink3.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/dev/ic/elink3.c b/sys/dev/ic/elink3.c
index b9eccaca299..0e01d583561 100644
--- a/sys/dev/ic/elink3.c
+++ b/sys/dev/ic/elink3.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: elink3.c,v 1.37 2000/02/02 18:47:01 deraadt Exp $ */
+/* $OpenBSD: elink3.c,v 1.38 2000/02/25 04:26:11 itojun Exp $ */
/* $NetBSD: elink3.c,v 1.32 1997/05/14 00:22:00 thorpej Exp $ */
/*
@@ -1245,6 +1245,7 @@ epget(sc, totlen)
sc->next_mb = (sc->next_mb + 1) % MAX_MBS;
m->m_data = m->m_pktdat;
m->m_flags = M_PKTHDR;
+ bzero(&m->m_pkthdr, sizeof(m->m_pkthdr));
}
m->m_pkthdr.rcvif = ifp;
m->m_pkthdr.len = totlen;