svn commit: r307076 - head/sys/kern

Ed Maste emaste at FreeBSD.org
Wed Oct 12 00:56:50 UTC 2016


Author: emaste
Date: Wed Oct 12 00:56:49 2016
New Revision: 307076
URL: https://svnweb.freebsd.org/changeset/base/307076

Log:
  Use correct size type in do_setopt_accept_filter
  
  Submitted by:	ecturt at gmail.com

Modified:
  head/sys/kern/uipc_accf.c

Modified: head/sys/kern/uipc_accf.c
==============================================================================
--- head/sys/kern/uipc_accf.c	Wed Oct 12 00:42:46 2016	(r307075)
+++ head/sys/kern/uipc_accf.c	Wed Oct 12 00:56:49 2016	(r307076)
@@ -250,7 +250,7 @@ do_setopt_accept_filter(struct socket *s
 	newaf = malloc(sizeof(*newaf), M_ACCF, M_WAITOK |
 	    M_ZERO);
 	if (afp->accf_create != NULL && afap->af_name[0] != '\0') {
-		int len = strlen(afap->af_name) + 1;
+		size_t len = strlen(afap->af_name) + 1;
 		newaf->so_accept_filter_str = malloc(len, M_ACCF,
 		    M_WAITOK);
 		strcpy(newaf->so_accept_filter_str, afap->af_name);


More information about the svn-src-head mailing list