Index: netinet/raw_ip.c =================================================================== --- netinet/raw_ip.c (revision 224592) +++ netinet/raw_ip.c (working copy) @@ -279,6 +279,13 @@ last = NULL; ifp = m->m_pkthdr.rcvif; + /* + * Add back the IP header length which was + * removed by ip_input(). Raw sockets do + * not modify the packet except for some + * byte order swaps. + */ + ip->ip_len += off; hash = INP_PCBHASH_RAW(proto, ip->ip_src.s_addr, ip->ip_dst.s_addr, V_ripcbinfo.ipi_hashmask);