Module Name:    src
Committed By:   martin
Date:           Thu Dec 12 19:29:05 UTC 2019

Modified Files:
        src/usr.sbin/sysinst: disklabel.c

Log Message:
Fix DISKLABEL_NO_ONDISK_VERIFY (accidently disabled in previous)


To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 src/usr.sbin/sysinst/disklabel.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/disklabel.c
diff -u src/usr.sbin/sysinst/disklabel.c:1.19 src/usr.sbin/sysinst/disklabel.c:1.20
--- src/usr.sbin/sysinst/disklabel.c:1.19	Thu Dec 12 12:19:39 2019
+++ src/usr.sbin/sysinst/disklabel.c	Thu Dec 12 19:29:05 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: disklabel.c,v 1.19 2019/12/12 12:19:39 martin Exp $	*/
+/*	$NetBSD: disklabel.c,v 1.20 2019/12/12 19:29:05 martin Exp $	*/
 
 /*
  * Copyright 2018 The NetBSD Foundation, Inc.
@@ -170,10 +170,10 @@ disklabel_parts_read(const char *disk, d
 	int fd;
 	char diskpath[MAXPATHLEN];
 	uint flags;
+#ifndef DISKLABEL_NO_ONDISK_VERIFY
 	bool only_dl = only_have_disklabel();
 	bool have_raw_label = false;
 
-#ifndef DISKLABEL_NO_ONDISK_VERIFY
 	/*
 	 * Verify we really have a disklabel.
 	 */
@@ -266,6 +266,7 @@ disklabel_parts_read(const char *disk, d
 	}
 	close(fd);
 
+#ifndef DISKLABEL_NO_ONDISK_VERIFY
 	if (!have_raw_label && only_dl) {
 		bool found_real_part = false;
 
@@ -288,6 +289,7 @@ disklabel_parts_read(const char *disk, d
 			return NULL;
 		}
 	}
+#endif
 
 	return &parts->dp;
 }

Reply via email to