summaryrefslogtreecommitdiffstats
path: root/usr.sbin/makefs
diff options
context:
space:
mode:
authornatano <natano@openbsd.org>2016-10-21 09:43:50 +0000
committernatano <natano@openbsd.org>2016-10-21 09:43:50 +0000
commitd4121caae41471a286b58ccf820662a607b2d278 (patch)
treeb3ffbf44266bde45cf28dd26c2349348c9836cdf /usr.sbin/makefs
parentRemove the superfluous 'sbsize' variable & s/sbsize/SBLOCKSIZE/. (diff)
downloadwireguard-openbsd-d4121caae41471a286b58ccf820662a607b2d278.tar.xz
wireguard-openbsd-d4121caae41471a286b58ccf820662a607b2d278.zip
Use the superblock passed to ffs_write_superblock() instead of referring
to the global 'sblock' variable for some operations.
Diffstat (limited to 'usr.sbin/makefs')
-rw-r--r--usr.sbin/makefs/ffs/mkfs.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/makefs/ffs/mkfs.c b/usr.sbin/makefs/ffs/mkfs.c
index 342efd75f89..234fec118c8 100644
--- a/usr.sbin/makefs/ffs/mkfs.c
+++ b/usr.sbin/makefs/ffs/mkfs.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mkfs.c,v 1.6 2016/10/21 09:38:31 natano Exp $ */
+/* $OpenBSD: mkfs.c,v 1.7 2016/10/21 09:43:50 natano Exp $ */
/* $NetBSD: mkfs.c,v 1.34 2016/06/24 19:24:11 christos Exp $ */
/*
@@ -532,7 +532,7 @@ ffs_write_superblock(struct fs *fs, const fsinfo_t *fsopts)
void *space;
char *wrbuf;
- memcpy(writebuf, &sblock, SBLOCKSIZE);
+ memcpy(writebuf, fs, SBLOCKSIZE);
ffs_wtfs(fs->fs_sblockloc / sectorsize, SBLOCKSIZE, writebuf, fsopts);
/* Write out the duplicate super blocks */