summaryrefslogtreecommitdiff
path: root/sbin/newlfs
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2002-05-22 08:21:03 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2002-05-22 08:21:03 +0000
commitf4157dcdc59508eeb6d7be5a9a2348bc1de796b2 (patch)
treeaa1086c2b95d7fcd3877479cd899d19157069519 /sbin/newlfs
parente2f0d51cf4e08e47c64eefc6043e0126ec941016 (diff)
strcpy, sprintf death; mpech ok
Diffstat (limited to 'sbin/newlfs')
-rw-r--r--sbin/newlfs/newfs.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sbin/newlfs/newfs.c b/sbin/newlfs/newfs.c
index de530d4448e..eb4c29f0a71 100644
--- a/sbin/newlfs/newfs.c
+++ b/sbin/newlfs/newfs.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: newfs.c,v 1.10 2002/03/14 16:44:24 mpech Exp $ */
+/* $OpenBSD: newfs.c,v 1.11 2002/05/22 08:21:02 deraadt Exp $ */
/* $NetBSD: newfs.c,v 1.5 1996/05/16 07:17:50 thorpej Exp $ */
/*-
@@ -44,7 +44,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)newfs.c 8.5 (Berkeley) 5/24/95";
#else
-static char rcsid[] = "$OpenBSD: newfs.c,v 1.10 2002/03/14 16:44:24 mpech Exp $";
+static char rcsid[] = "$OpenBSD: newfs.c,v 1.11 2002/05/22 08:21:02 deraadt Exp $";
#endif
#endif /* not lint */
@@ -410,7 +410,7 @@ rewritelabel(s, fd, lp)
/*
* Make name for 'c' partition.
*/
- strcpy(specname, s);
+ strlcpy(specname, s, sizeof specname);
cp = specname + strlen(specname) - 1;
if (!isdigit(*cp))
*cp = 'c';