Module Name:    src
Committed By:   martin
Date:           Sun Oct 18 09:21:55 UTC 2015

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

Log Message:
PR 50342: if there is no current partition manage, assume we are running
from an already installed system.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/usr.sbin/sysinst/target.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/target.c
diff -u src/usr.sbin/sysinst/target.c:1.2 src/usr.sbin/sysinst/target.c:1.3
--- src/usr.sbin/sysinst/target.c:1.2	Sun Aug  3 16:09:38 2014
+++ src/usr.sbin/sysinst/target.c	Sun Oct 18 09:21:55 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: target.c,v 1.2 2014/08/03 16:09:38 martin Exp $	*/
+/*	$NetBSD: target.c,v 1.3 2015/10/18 09:21:55 martin Exp $	*/
 
 /*
  * Copyright 1997 Jonathan Stone
@@ -71,7 +71,7 @@
 
 #include <sys/cdefs.h>
 #if defined(LIBC_SCCS) && !defined(lint)
-__RCSID("$NetBSD: target.c,v 1.2 2014/08/03 16:09:38 martin Exp $");
+__RCSID("$NetBSD: target.c,v 1.3 2015/10/18 09:21:55 martin Exp $");
 #endif
 
 /*
@@ -153,6 +153,9 @@ int
 target_already_root(void)
 {
 
+	if (pm == NULL)
+		return TRUE;
+
 	if (strcmp(pm->diskdev, "") == 0)
 		/* No root partition was ever selected.
 		 * Assume that the currently mounted one should be used

Reply via email to