]> git.saurik.com Git - apple/xnu.git/blobdiff - bsd/netinet/ip_output.c
xnu-201.42.3.tar.gz
[apple/xnu.git] / bsd / netinet / ip_output.c
index 1018b8d21a12055ed0c82f538ac5cb21f85c40c5..fa63025aa9d0e137ec17009f3428fb514ae40feb 100644 (file)
@@ -351,8 +351,10 @@ ip_output(m0, opt, ro, flags, imo)
                 */
                if (imo != NULL) {
                        ip->ip_ttl = imo->imo_multicast_ttl;
-                       if (imo->imo_multicast_ifp != NULL)
+                       if (imo->imo_multicast_ifp != NULL) {
                                ifp = imo->imo_multicast_ifp;
+                               dl_tag = ifp->if_data.default_proto;
+                       }
                        if (imo->imo_multicast_vif != -1)
                                ip->ip_src.s_addr =
                                    ip_mcast_src(imo->imo_multicast_vif);
@@ -1043,7 +1045,7 @@ in_delayed_cksum(struct mbuf *m)
 
         csum = in_cksum_skip(m, ip->ip_len, offset);
 
-       if (csum == 0)
+       if ((m->m_pkthdr.csum_flags & CSUM_UDP) && csum == 0)
                csum = 0xffff;
 
         offset += m->m_pkthdr.csum_data & 0xFFFF;        /* checksum offset */