svn commit: r327018 - stable/11/libexec/ftpd

Xin LI delphij at FreeBSD.org
Wed Dec 20 07:16:42 UTC 2017


Author: delphij
Date: Wed Dec 20 07:16:41 2017
New Revision: 327018
URL: https://svnweb.freebsd.org/changeset/base/327018

Log:
  MFC r326562: Use strlcpy().

Modified:
  stable/11/libexec/ftpd/ftpd.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/libexec/ftpd/ftpd.c
==============================================================================
--- stable/11/libexec/ftpd/ftpd.c	Wed Dec 20 06:08:16 2017	(r327017)
+++ stable/11/libexec/ftpd/ftpd.c	Wed Dec 20 07:16:41 2017	(r327018)
@@ -1075,7 +1075,7 @@ user(char *name)
 		}
 	}
 	if (logging)
-		strncpy(curname, name, sizeof(curname)-1);
+		strlcpy(curname, name, sizeof(curname));
 
 	pwok = 0;
 #ifdef USE_PAM


More information about the svn-src-all mailing list