Fix error in r241913 that had broken fragment reassembly.

This commit is contained in:
Gleb Smirnoff 2012-10-25 09:00:57 +00:00
parent 2e3ee2392a
commit b6fcf6f9f5
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=242076

View File

@ -904,7 +904,7 @@ ip_reass(struct mbuf *m)
* Make sure that fragments have a data length
* that's a non-zero multiple of 8 bytes.
*/
if (ntohs(ip->ip_len) == 0 || (ntohs(ip->ip_len & 0x7) != 0)) {
if (ip->ip_len == htons(0) || (ntohs(ip->ip_len) & 0x7) != 0) {
IPSTAT_INC(ips_toosmall); /* XXX */
goto dropfrag;
}