Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-1-6]: src/distrib/utils/sysinst/arch/i386 Pull up revision 1.65 (...
details: https://anonhg.NetBSD.org/src/rev/a30ddb0dc71f
branches: netbsd-1-6
changeset: 529068:a30ddb0dc71f
user: lukem <lukem%NetBSD.org@localhost>
date: Wed Sep 04 14:30:45 2002 +0000
description:
Pull up revision 1.65 (requested by jdolecek in ticket #771):
Do not get confused by empty MBR when gathering information for disk layout.
This fixes install/18153 by Johnny C. Lam.
Base for fix provided by Tyler Retzlaff. Tested by Tyler, Grant Beattie & me.
diffstat:
distrib/utils/sysinst/arch/i386/md.c | 11 ++++++++++-
1 files changed, 10 insertions(+), 1 deletions(-)
diffs (25 lines):
diff -r 60452dcab66b -r a30ddb0dc71f distrib/utils/sysinst/arch/i386/md.c
--- a/distrib/utils/sysinst/arch/i386/md.c Wed Sep 04 14:06:10 2002 +0000
+++ b/distrib/utils/sysinst/arch/i386/md.c Wed Sep 04 14:30:45 2002 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: md.c,v 1.58.2.4 2002/08/02 10:36:38 lukem Exp $ */
+/* $NetBSD: md.c,v 1.58.2.5 2002/09/04 14:30:45 lukem Exp $ */
/*
* Copyright 1997 Piermont Information Systems Inc.
@@ -342,6 +342,15 @@
#define p l.d_partitions[i]
for (i = 0; i < maxpart; i++) {
+ /*
+ * Make sure to not overwrite the NetBSD partition
+ * with blank values. Might happen when MBR doesn't
+ * contain any NetBSD entry yet, and the disklabel
+ * is fabricated by kernel.
+ */
+ if (i == 2 && p.p_size == 0)
+ continue;
+
bsdlabel[i].pi_size = p.p_size;
bsdlabel[i].pi_offset = p.p_offset;
bsdlabel[i].pi_fstype = p.p_fstype;
Home |
Main Index |
Thread Index |
Old Index