Module Name:    src
Committed By:   martin
Date:           Fri Jan 10 12:55:14 UTC 2020

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

Log Message:
When asked to create a whole-disk partition for unknown usage, do not only
assert(false), but actually return an error (in case "assert" is a nop).


To generate a diff of this commit:
cvs rdiff -u -r1.46 -r1.47 src/usr.sbin/sysinst/partman.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/partman.c
diff -u src/usr.sbin/sysinst/partman.c:1.46 src/usr.sbin/sysinst/partman.c:1.47
--- src/usr.sbin/sysinst/partman.c:1.46	Thu Jan  9 13:22:30 2020
+++ src/usr.sbin/sysinst/partman.c	Fri Jan 10 12:55:14 2020
@@ -1,4 +1,4 @@
-/*	$NetBSD: partman.c,v 1.46 2020/01/09 13:22:30 martin Exp $ */
+/*	$NetBSD: partman.c,v 1.47 2020/01/10 12:55:14 martin Exp $ */
 
 /*
  * Copyright 2012 Eugene Lozovoy
@@ -3299,6 +3299,7 @@ pm_whole_disk(struct part_entry *pe, int
 		break;
 	default:
 		assert(false); 
+		return NO_PART;
 	}
 	info.nat_type = parts->pscheme->get_fs_part_type(PT_root, fst, 0);
 	if (info.nat_type != NULL && parts->pscheme->get_default_fstype != NULL)

Reply via email to