diff options
author | jlemon <jlemon@FreeBSD.org> | 2000-04-01 18:51:03 +0000 |
---|---|---|
committer | jlemon <jlemon@FreeBSD.org> | 2000-04-01 18:51:03 +0000 |
commit | bdc5c086d98317a835570edc1bbbb80fe69b8936 (patch) | |
tree | 019deb10f897b6ebbaed77cc33cca1163b51d025 | |
parent | 0532ba1ec247bf19c0b08f1638387dfabcba6faa (diff) | |
download | FreeBSD-src-bdc5c086d98317a835570edc1bbbb80fe69b8936.zip FreeBSD-src-bdc5c086d98317a835570edc1bbbb80fe69b8936.tar.gz |
Calculate any delayed checksums before handing an mbuf off to a
divert socket. This fixes a problem with ppp/natd.
Reviewed by: bsd (Brian Dean, gotta love that login name)
-rw-r--r-- | sys/netinet/ip_output.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/sys/netinet/ip_output.c b/sys/netinet/ip_output.c index 9a983a1..60d34f7 100644 --- a/sys/netinet/ip_output.c +++ b/sys/netinet/ip_output.c @@ -506,6 +506,16 @@ sendit: if ((off & IP_FW_PORT_TEE_FLAG) != 0) clone = m_dup(m, M_DONTWAIT); + /* + * XXX + * delayed checksums are not currently compatible + * with divert sockets. + */ + if (m->m_pkthdr.csum_flags & CSUM_DELAY_DATA) { + in_delayed_cksum(m); + m->m_pkthdr.csum_flags &= ~CSUM_DELAY_DATA; + } + /* Restore packet header fields to original values */ HTONS(ip->ip_len); HTONS(ip->ip_off); |