svn commit: r212099 - head/sys/netinet

Michael Tuexen tuexen at FreeBSD.org
Wed Sep 1 16:11:27 UTC 2010


Author: tuexen
Date: Wed Sep  1 16:11:26 2010
New Revision: 212099
URL: http://svn.freebsd.org/changeset/base/212099

Log:
  Fix a bug which results in peer IPv4 addresses a.b.c.d with 224<=d<=239
  incorrectly being detected as multicast addresses on little endian systems.
  
  MFC after: 2 weeks

Modified:
  head/sys/netinet/sctp_pcb.c

Modified: head/sys/netinet/sctp_pcb.c
==============================================================================
--- head/sys/netinet/sctp_pcb.c	Wed Sep  1 15:24:47 2010	(r212098)
+++ head/sys/netinet/sctp_pcb.c	Wed Sep  1 16:11:26 2010	(r212099)
@@ -5988,7 +5988,7 @@ sctp_load_addresses_from_init(struct sct
 				}
 				p4 = (struct sctp_ipv4addr_param *)phdr;
 				sin.sin_addr.s_addr = p4->addr;
-				if (IN_MULTICAST(sin.sin_addr.s_addr)) {
+				if (IN_MULTICAST(ntohl(sin.sin_addr.s_addr))) {
 					/* Skip multi-cast addresses */
 					goto next_param;
 				}


More information about the svn-src-head mailing list