Diff reduction with NetBSD; use IN_LOCAL_GROUP() to check if an address

is within the locally scoped multicast range 224.0.0.0/24.
This commit is contained in:
Bruce M Simpson 2007-03-15 08:44:22 +00:00
parent 00b08b94fe
commit 5c51891ef7
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=167593

View File

@ -1350,7 +1350,7 @@ X_ip_mforward(struct ip *ip, struct ifnet *ifp, struct mbuf *m,
* Don't forward a packet with time-to-live of zero or one,
* or a packet destined to a local-only group.
*/
if (ip->ip_ttl <= 1 || ntohl(ip->ip_dst.s_addr) <= INADDR_MAX_LOCAL_GROUP) {
if (ip->ip_ttl <= 1 || IN_LOCAL_GROUP(ntohl(ip->ip_dst.s_addr))) {
MFC_UNLOCK();
VIF_UNLOCK();
return 0;