Properly handle partitions that we were requested to mount but not newfs.

This commit is contained in:
martin 2019-08-03 12:09:22 +00:00
parent 20e0cdbea1
commit a8e7688bfa
1 changed files with 3 additions and 6 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: disks.c,v 1.45 2019/08/01 16:32:06 martin Exp $ */ /* $NetBSD: disks.c,v 1.46 2019/08/03 12:09:22 martin Exp $ */
/* /*
* Copyright 1997 Piermont Information Systems Inc. * Copyright 1997 Piermont Information Systems Inc.
@ -1112,7 +1112,7 @@ make_filesystems(struct install_partition_desc *install)
ptn = &install->infos[i]; ptn = &install->infos[i];
parts = ptn->parts; parts = ptn->parts;
if (ptn->size == 0 || parts == NULL) if (ptn->size == 0 || parts == NULL|| ptn->type == PT_swap)
continue; continue;
if (parts->pscheme->get_part_device(parts, ptn->cur_part_id, if (parts->pscheme->get_part_device(parts, ptn->cur_part_id,
@ -1120,9 +1120,6 @@ make_filesystems(struct install_partition_desc *install)
&& is_active_rootpart(devdev, partno)) && is_active_rootpart(devdev, partno))
continue; continue;
if (!(ptn->instflags & PUIINST_NEWFS))
continue;
parts->pscheme->get_part_device(parts, ptn->cur_part_id, parts->pscheme->get_part_device(parts, ptn->cur_part_id,
devdev, sizeof devdev, &partno, plain_name, true); devdev, sizeof devdev, &partno, plain_name, true);