diff options
author | 2000-04-13 19:22:57 +0000 | |
---|---|---|
committer | 2000-04-13 19:22:57 +0000 | |
commit | e0dcbbef8815a46b1a90a5065fa441e14be4e9f9 (patch) | |
tree | 777d72cd123a59d8670d54148cd076d2b0364216 /sys/netinet | |
parent | neo (diff) | |
download | wireguard-openbsd-e0dcbbef8815a46b1a90a5065fa441e14be4e9f9.tar.xz wireguard-openbsd-e0dcbbef8815a46b1a90a5065fa441e14be4e9f9.zip |
When fragmenting a packet, inherit the multicast and broadcast flags so that
the link layer can choose the right address.
Diffstat (limited to 'sys/netinet')
-rw-r--r-- | sys/netinet/ip_output.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/netinet/ip_output.c b/sys/netinet/ip_output.c index b422090adf0..211b954f364 100644 --- a/sys/netinet/ip_output.c +++ b/sys/netinet/ip_output.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ip_output.c,v 1.66 2000/03/30 04:53:36 angelos Exp $ */ +/* $OpenBSD: ip_output.c,v 1.67 2000/04/13 19:22:57 art Exp $ */ /* $NetBSD: ip_output.c,v 1.28 1996/02/13 23:43:07 christos Exp $ */ /* @@ -756,6 +756,8 @@ no_encap: m->m_data += max_linkhdr; mhip = mtod(m, struct ip *); *mhip = *ip; + /* we must inherit MCAST and BCAST flags */ + m->m_flags |= m0->m_flags & (M_MCAST|M_BCAST); if (hlen > sizeof (struct ip)) { mhlen = ip_optcopy(ip, mhip) + sizeof (struct ip); mhip->ip_hl = mhlen >> 2; |