mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-11-29 17:32:43 +00:00
Fix a bug whereby multicast packets that are looped back locally
wind up with the incorrect checksum on the wire when transmitted via devices that do checksum offloading. PR: kern/119635 Reviewed by: rwatson MFC after: 5 days
This commit is contained in:
parent
12dc95824b
commit
e4762f75c3
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=182463
@ -1146,7 +1146,11 @@ ip_mloopback(struct ifnet *ifp, struct mbuf *m, struct sockaddr_in *dst,
|
||||
register struct ip *ip;
|
||||
struct mbuf *copym;
|
||||
|
||||
copym = m_copy(m, 0, M_COPYALL);
|
||||
/*
|
||||
* Make a deep copy of the packet because we're going to
|
||||
* modify the pack in order to generate checksums.
|
||||
*/
|
||||
copym = m_dup(m, M_DONTWAIT);
|
||||
if (copym != NULL && (copym->m_flags & M_EXT || copym->m_len < hlen))
|
||||
copym = m_pullup(copym, hlen);
|
||||
if (copym != NULL) {
|
||||
|
Loading…
Reference in New Issue
Block a user