svn commit: r272296 - head/sys/netinet6

Kevin Lo kevlo at FreeBSD.org
Tue Sep 30 07:28:32 UTC 2014


Author: kevlo
Date: Tue Sep 30 07:28:31 2014
New Revision: 272296
URL: http://svnweb.freebsd.org/changeset/base/272296

Log:
  When plen != ulen, it should only be checked when this is UDP.
  
  Spotted by:	bryanv

Modified:
  head/sys/netinet6/udp6_usrreq.c

Modified: head/sys/netinet6/udp6_usrreq.c
==============================================================================
--- head/sys/netinet6/udp6_usrreq.c	Tue Sep 30 05:50:34 2014	(r272295)
+++ head/sys/netinet6/udp6_usrreq.c	Tue Sep 30 07:28:31 2014	(r272296)
@@ -232,7 +232,7 @@ udp6_input(struct mbuf **mp, int *offp, 
 		ulen = plen;
 		cscov_partial = 0;
 	}
-	if (plen != ulen) {
+	if (nxt == IPPROTO_UDP && plen != ulen) {
 		UDPSTAT_INC(udps_badlen);
 		goto badunlocked;
 	}


More information about the svn-src-all mailing list