Module Name:    src
Committed By:   mrg
Date:           Sat Oct  5 22:06:29 UTC 2019

Modified Files:
        src/tests/fs/common: fstest_nfs.c

Log Message:
sprintf->snprintf


To generate a diff of this commit:
cvs rdiff -u -r1.10 -r1.11 src/tests/fs/common/fstest_nfs.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/tests/fs/common/fstest_nfs.c
diff -u src/tests/fs/common/fstest_nfs.c:1.10 src/tests/fs/common/fstest_nfs.c:1.11
--- src/tests/fs/common/fstest_nfs.c:1.10	Fri Feb  1 09:06:07 2019
+++ src/tests/fs/common/fstest_nfs.c	Sat Oct  5 22:06:29 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: fstest_nfs.c,v 1.10 2019/02/01 09:06:07 mrg Exp $	*/
+/*	$NetBSD: fstest_nfs.c,v 1.11 2019/10/05 22:06:29 mrg Exp $	*/
 
 /*
  * Copyright (c) 2010 The NetBSD Foundation, Inc.
@@ -87,10 +87,12 @@ donewfs(const atf_tc_t *tc, void **argp,
 	 * First, we start the nfs service.
 	 */
 	srcdir = atf_tc_get_config_var(tc, "srcdir");
-	sprintf(nfsdpath, "%s/../nfs/nfsservice/rumpnfsd", srcdir);
-	sprintf(ethername, "/%s/%s.etherbus", getcwd(cwd, sizeof(cwd)), image);
-	sprintf(ethername_ro, "%s_ro", ethername);
-	sprintf(imagepath, "/%s/%s", cwd, image);
+	snprintf(nfsdpath, sizeof nfsdpath,
+	    "%s/../nfs/nfsservice/rumpnfsd", srcdir);
+	snprintf(ethername, sizeof ethername,
+	    "/%s/%s.etherbus", getcwd(cwd, sizeof(cwd)), image);
+	snprintf(ethername_ro, sizeof ethername_ro, "%s_ro", ethername);
+	snprintf(imagepath, sizeof imagepath, "/%s/%s", cwd, image);
 
 	nfsdargv[0] = nfsdpath;
 	nfsdargv[1] = ethername;

Reply via email to