be sure to wipe out m_pkthdr when you set M_PKTHDR, you may see junk pointer
in m_pkthdr portion. actually, we should not change pkthdr mbuf <-> non-pkthdr mbuf.
This commit is contained in:
parent
2881f702c7
commit
2f0dab8f41
@ -306,6 +306,7 @@ chain_mbufs(lnc_softc_t *sc, int start_of_packet, int pkt_len)
|
||||
|
||||
head = desc->buff.mbuf;
|
||||
head->m_flags |= M_PKTHDR;
|
||||
bzero(&head->m_pkthdr, sizeof(head->m_pkthdr));
|
||||
|
||||
m = head;
|
||||
do {
|
||||
|
@ -813,7 +813,7 @@ vxget(sc, totlen)
|
||||
sc->next_mb = (sc->next_mb + 1) % MAX_MBS;
|
||||
m->m_data = m->m_pktdat;
|
||||
m->m_flags = M_PKTHDR;
|
||||
m->m_pkthdr.csum_flags = 0;
|
||||
bzero(&m->m_pkthdr, sizeof(m->m_pkthdr));
|
||||
}
|
||||
m->m_pkthdr.rcvif = ifp;
|
||||
m->m_pkthdr.len = totlen;
|
||||
|
Loading…
Reference in New Issue
Block a user