diff options
author | natano <natano@openbsd.org> | 2016-11-08 19:38:57 +0000 |
---|---|---|
committer | natano <natano@openbsd.org> | 2016-11-08 19:38:57 +0000 |
commit | b89d7d0503308ac438a92a8ce12f49b278350266 (patch) | |
tree | 1c1457fa66e56ed1fbd48936bb60705161b5dd07 /usr.sbin/makefs | |
parent | Add support for sun9i-a80, the Allwinner A80. (diff) | |
download | wireguard-openbsd-b89d7d0503308ac438a92a8ce12f49b278350266.tar.xz wireguard-openbsd-b89d7d0503308ac438a92a8ce12f49b278350266.zip |
Respect -Ooffset for the disklabel location.
Diffstat (limited to 'usr.sbin/makefs')
-rw-r--r-- | usr.sbin/makefs/ffs.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/makefs/ffs.c b/usr.sbin/makefs/ffs.c index 9206814128b..fdba04ff06a 100644 --- a/usr.sbin/makefs/ffs.c +++ b/usr.sbin/makefs/ffs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ffs.c,v 1.21 2016/11/08 19:22:29 natano Exp $ */ +/* $OpenBSD: ffs.c,v 1.22 2016/11/08 19:38:57 natano Exp $ */ /* $NetBSD: ffs.c,v 1.66 2015/12/21 00:58:08 christos Exp $ */ /* @@ -293,7 +293,7 @@ ffs_makefs(const char *image, const char *dir, fsnode *root, fsinfo_t *fsopts) lp->d_checksum = sum; n = pwrite(fsopts->fd, lp, sizeof(struct disklabel), - DOS_LABELSECTOR * DEV_BSIZE); + fsopts->offset + DOS_LABELSECTOR * DEV_BSIZE); if (n == -1) err(1, "failed to write disklabel"); else if (n < sizeof(struct disklabel)) |