Module Name: src Committed By: martin Date: Thu Aug 8 13:45:19 UTC 2019
Modified Files: src/usr.sbin/sysinst: disks.c Log Message: Do not even consider to fsck partitions where we do not know the file system type. Add v7fs support. To generate a diff of this commit: cvs rdiff -u -r1.49 -r1.50 src/usr.sbin/sysinst/disks.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/usr.sbin/sysinst/disks.c diff -u src/usr.sbin/sysinst/disks.c:1.49 src/usr.sbin/sysinst/disks.c:1.50 --- src/usr.sbin/sysinst/disks.c:1.49 Thu Aug 8 11:41:16 2019 +++ src/usr.sbin/sysinst/disks.c Thu Aug 8 13:45:19 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: disks.c,v 1.49 2019/08/08 11:41:16 martin Exp $ */ +/* $NetBSD: disks.c,v 1.50 2019/08/08 13:45:19 martin Exp $ */ /* * Copyright 1997 Piermont Information Systems Inc. @@ -1121,6 +1121,8 @@ make_filesystems(struct install_partitio */ ptn = &install->infos[i]; parts = ptn->parts; + newfs = NULL; + fsname = NULL; if (ptn->size == 0 || parts == NULL|| ptn->type == PT_swap) continue; @@ -1136,7 +1138,6 @@ make_filesystems(struct install_partitio parts->pscheme->get_part_device(parts, ptn->cur_part_id, rdev, sizeof rdev, &partno, raw_dev_name, true); - newfs = NULL; switch (ptn->fs_type) { case FS_APPLEUFS: asprintf(&newfs, "/sbin/newfs"); @@ -1168,6 +1169,11 @@ make_filesystems(struct install_partitio mnt_opts = "-tsysvbfs"; fsname = "sysvbfs"; break; + case FS_V7: + asprintf(&newfs, "/sbin/newfs_v7fs"); + mnt_opts = "-tv7fs"; + fsname = "v7fs"; + break; case FS_EX2FS: asprintf(&newfs, "/sbin/newfs_ext2fs"); mnt_opts = "-text2fs"; @@ -1192,7 +1198,8 @@ make_filesystems(struct install_partitio error = run_program(RUN_DISPLAY | RUN_PROGRESS, "%s %s", newfs, rdev); } - } else if (ptn->instflags & (PUIINST_MOUNT|PUIINST_BOOT)) { + } else if ((ptn->instflags & (PUIINST_MOUNT|PUIINST_BOOT)) + && fsname != NULL) { /* We'd better check it isn't dirty */ error = fsck_preen(devdev, fsname, false); }