aboutsummaryrefslogtreecommitdiff
path: root/sbin/newfs/mkfs.c
diff options
context:
space:
mode:
authorBill Fumerola <billf@FreeBSD.org>1999-08-21 22:07:27 +0000
committerBill Fumerola <billf@FreeBSD.org>1999-08-21 22:07:27 +0000
commit5682c39f91506357cdc071f7abc55bb63d1e0c85 (patch)
tree5a0958ddeea23f1ee0e305c09f4fcba05ed12fc7 /sbin/newfs/mkfs.c
parent775ef6178d805239ee0698b3ae14a04b38468457 (diff)
downloadsrc-5682c39f91506357cdc071f7abc55bb63d1e0c85.tar.gz
src-5682c39f91506357cdc071f7abc55bb63d1e0c85.zip
Don't print a "," after the last superblock.
Submitted by: adrian
Notes
Notes: svn path=/head/; revision=50134
Diffstat (limited to 'sbin/newfs/mkfs.c')
-rw-r--r--sbin/newfs/mkfs.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/sbin/newfs/mkfs.c b/sbin/newfs/mkfs.c
index 59957fba7c1b..70e1c553ee95 100644
--- a/sbin/newfs/mkfs.c
+++ b/sbin/newfs/mkfs.c
@@ -36,7 +36,7 @@
static char sccsid[] = "@(#)mkfs.c 8.11 (Berkeley) 5/3/95";
#endif
static const char rcsid[] =
- "$Id: mkfs.c,v 1.26 1998/08/27 07:38:33 dfr Exp $";
+ "$Id: mkfs.c,v 1.27 1999/02/09 17:19:18 dillon Exp $";
#endif /* not lint */
#include <err.h>
@@ -686,8 +686,9 @@ next:
initcg(cylno, utime);
if (mfs)
continue;
- j = sprintf(tmpbuf, " %ld,",
- fsbtodb(&sblock, cgsblock(&sblock, cylno)));
+ j = sprintf(tmpbuf, " %ld%s",
+ fsbtodb(&sblock, cgsblock(&sblock, cylno)),
+ cylno < (sblock.fs_ncg-1) ? "," : "" );
if (i + j >= width) {
printf("\n");
i = 0;