aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sbin/newfs_msdos/mkfs_msdos.c2
-rw-r--r--sbin/newfs_msdos/newfs_msdos.c8
2 files changed, 5 insertions, 5 deletions
diff --git a/sbin/newfs_msdos/mkfs_msdos.c b/sbin/newfs_msdos/mkfs_msdos.c
index c2cdebaccd17..c14f33d95bfb 100644
--- a/sbin/newfs_msdos/mkfs_msdos.c
+++ b/sbin/newfs_msdos/mkfs_msdos.c
@@ -715,7 +715,7 @@ mkfs_msdos(const char *fname, const char *dtype, const struct msdos_options *op)
mk4(img, 0x41615252);
mk4(img + MINBPS - 28, 0x61417272);
mk4(img + MINBPS - 24, 0xffffffff);
- mk4(img + MINBPS - 20, bpb.bpbRootClust);
+ mk4(img + MINBPS - 20, 0xffffffff);
mk2(img + MINBPS - 2, DOSMAGIC);
} else if (lsn >= bpb.bpbResSectors && lsn < dir &&
!((lsn - bpb.bpbResSectors) %
diff --git a/sbin/newfs_msdos/newfs_msdos.c b/sbin/newfs_msdos/newfs_msdos.c
index e3528ab1828e..bac250e7dd05 100644
--- a/sbin/newfs_msdos/newfs_msdos.c
+++ b/sbin/newfs_msdos/newfs_msdos.c
@@ -178,10 +178,10 @@ main(int argc, char *argv[])
argv += optind;
if (argc < 1 || argc > 2)
usage();
- if (o.align) {
- if (o.hidden_sectors_set)
- errx(1, "align (-A) is incompatible with -r");
- }
+ if (o.align) {
+ if (o.reserved_sectors)
+ errx(1, "align (-A) is incompatible with -r");
+ }
fname = *argv++;
if (!o.create_size && !strchr(fname, '/')) {
snprintf(buf, sizeof(buf), "%s%s", _PATH_DEV, fname);