svn commit: r268867 - head/lib/libc/net

Pedro F. Giffuni pfg at FreeBSD.org
Sat Jul 19 01:53:52 UTC 2014


Author: pfg
Date: Sat Jul 19 01:53:52 2014
New Revision: 268867
URL: http://svnweb.freebsd.org/changeset/base/268867

Log:
  Use unsigned optlen in getsourcefilter()
  
  Sizes can not be negative and the functions that use it
  expect an unsigned value anyways.
  
  Obtained from:	Apple (Libc-997.90.3)
  MFC after:	1 week

Modified:
  head/lib/libc/net/sourcefilter.c

Modified: head/lib/libc/net/sourcefilter.c
==============================================================================
--- head/lib/libc/net/sourcefilter.c	Sat Jul 19 01:15:01 2014	(r268866)
+++ head/lib/libc/net/sourcefilter.c	Sat Jul 19 01:53:52 2014	(r268867)
@@ -337,7 +337,8 @@ getsourcefilter(int s, uint32_t interfac
 {
 	struct __msfilterreq	 msfr;
 	sockunion_t		*psu;
-	int			 err, level, nsrcs, optlen, optname;
+	int			 err, level, nsrcs, optname;
+	unsigned int		 optlen;
 
 	if (interface == 0 || group == NULL || numsrc == NULL ||
 	    fmode == NULL) {


More information about the svn-src-head mailing list