diff options
-rw-r--r-- | release/sysinstall/cdrom.c | 4 | ||||
-rw-r--r-- | release/sysinstall/install.c | 10 | ||||
-rw-r--r-- | usr.sbin/sade/install.c | 10 | ||||
-rw-r--r-- | usr.sbin/sysinstall/cdrom.c | 4 | ||||
-rw-r--r-- | usr.sbin/sysinstall/install.c | 10 |
5 files changed, 29 insertions, 9 deletions
diff --git a/release/sysinstall/cdrom.c b/release/sysinstall/cdrom.c index 438c2e6..b5cc153 100644 --- a/release/sysinstall/cdrom.c +++ b/release/sysinstall/cdrom.c @@ -4,7 +4,7 @@ * This is probably the last attempt in the `sysinstall' line, the next * generation being slated to essentially a complete rewrite. * - * $Id: cdrom.c,v 1.31 1997/01/01 12:36:05 jkh Exp $ + * $Id: cdrom.c,v 1.32 1997/01/06 11:10:21 jkh Exp $ * * Copyright (c) 1995 * Jordan Hubbard. All rights reserved. @@ -108,8 +108,6 @@ mediaInitCDROM(Device *dev) cdromMounted = CD_ALREADY_MOUNTED; if (readInfo && (DITEM_STATUS(attr_parse_file(cd_attr, "/cdrom/cdrom.inf")) == DITEM_FAILURE || !(cp = attr_match(cd_attr, "CD_VERSION")) || strcmp(cp, variable_get(VAR_RELNAME)))) { - if (cdromMounted != CD_ALREADY_MOUNTED) - unmount("/cdrom", MNT_FORCE); if (!cp) msgConfirm("Unable to find a /cdrom/cdrom.inf file.\n" "Either this is not a FreeBSD CDROM, there is a problem with\n" diff --git a/release/sysinstall/install.c b/release/sysinstall/install.c index cf5abaa..5a95165 100644 --- a/release/sysinstall/install.c +++ b/release/sysinstall/install.c @@ -4,7 +4,7 @@ * This is probably the last program in the `sysinstall' line - the next * generation being essentially a complete rewrite. * - * $Id: install.c,v 1.147 1996/12/29 05:51:35 jkh Exp $ + * $Id: install.c,v 1.148 1997/01/06 11:10:25 jkh Exp $ * * Copyright (c) 1995 * Jordan Hubbard. All rights reserved. @@ -254,6 +254,9 @@ installFixitCDROM(dialogMenuItem *self) { struct stat sb; + if (!RunningAsInit) + return DITEM_SUCCESS; + variable_set2(SYSTEM_STATE, "fixit"); (void)unlink("/mnt2"); (void)rmdir("/mnt2"); @@ -269,6 +272,8 @@ installFixitCDROM(dialogMenuItem *self) if (msgYesNo("Unable to mount the CDROM - do you want to try again?") != 0) return DITEM_FAILURE; } + else + break; } /* Since the fixit code expects everything to be in /mnt2, and the CDROM mounting stuff /cdrom, do @@ -323,6 +328,9 @@ installFixitFloppy(dialogMenuItem *self) { struct ufs_args args; + if (!RunningAsInit) + return DITEM_SUCCESS; + variable_set2(SYSTEM_STATE, "fixit"); memset(&args, 0, sizeof(args)); args.fspec = "/dev/fd0"; diff --git a/usr.sbin/sade/install.c b/usr.sbin/sade/install.c index cf5abaa..5a95165 100644 --- a/usr.sbin/sade/install.c +++ b/usr.sbin/sade/install.c @@ -4,7 +4,7 @@ * This is probably the last program in the `sysinstall' line - the next * generation being essentially a complete rewrite. * - * $Id: install.c,v 1.147 1996/12/29 05:51:35 jkh Exp $ + * $Id: install.c,v 1.148 1997/01/06 11:10:25 jkh Exp $ * * Copyright (c) 1995 * Jordan Hubbard. All rights reserved. @@ -254,6 +254,9 @@ installFixitCDROM(dialogMenuItem *self) { struct stat sb; + if (!RunningAsInit) + return DITEM_SUCCESS; + variable_set2(SYSTEM_STATE, "fixit"); (void)unlink("/mnt2"); (void)rmdir("/mnt2"); @@ -269,6 +272,8 @@ installFixitCDROM(dialogMenuItem *self) if (msgYesNo("Unable to mount the CDROM - do you want to try again?") != 0) return DITEM_FAILURE; } + else + break; } /* Since the fixit code expects everything to be in /mnt2, and the CDROM mounting stuff /cdrom, do @@ -323,6 +328,9 @@ installFixitFloppy(dialogMenuItem *self) { struct ufs_args args; + if (!RunningAsInit) + return DITEM_SUCCESS; + variable_set2(SYSTEM_STATE, "fixit"); memset(&args, 0, sizeof(args)); args.fspec = "/dev/fd0"; diff --git a/usr.sbin/sysinstall/cdrom.c b/usr.sbin/sysinstall/cdrom.c index 438c2e6..b5cc153 100644 --- a/usr.sbin/sysinstall/cdrom.c +++ b/usr.sbin/sysinstall/cdrom.c @@ -4,7 +4,7 @@ * This is probably the last attempt in the `sysinstall' line, the next * generation being slated to essentially a complete rewrite. * - * $Id: cdrom.c,v 1.31 1997/01/01 12:36:05 jkh Exp $ + * $Id: cdrom.c,v 1.32 1997/01/06 11:10:21 jkh Exp $ * * Copyright (c) 1995 * Jordan Hubbard. All rights reserved. @@ -108,8 +108,6 @@ mediaInitCDROM(Device *dev) cdromMounted = CD_ALREADY_MOUNTED; if (readInfo && (DITEM_STATUS(attr_parse_file(cd_attr, "/cdrom/cdrom.inf")) == DITEM_FAILURE || !(cp = attr_match(cd_attr, "CD_VERSION")) || strcmp(cp, variable_get(VAR_RELNAME)))) { - if (cdromMounted != CD_ALREADY_MOUNTED) - unmount("/cdrom", MNT_FORCE); if (!cp) msgConfirm("Unable to find a /cdrom/cdrom.inf file.\n" "Either this is not a FreeBSD CDROM, there is a problem with\n" diff --git a/usr.sbin/sysinstall/install.c b/usr.sbin/sysinstall/install.c index cf5abaa..5a95165 100644 --- a/usr.sbin/sysinstall/install.c +++ b/usr.sbin/sysinstall/install.c @@ -4,7 +4,7 @@ * This is probably the last program in the `sysinstall' line - the next * generation being essentially a complete rewrite. * - * $Id: install.c,v 1.147 1996/12/29 05:51:35 jkh Exp $ + * $Id: install.c,v 1.148 1997/01/06 11:10:25 jkh Exp $ * * Copyright (c) 1995 * Jordan Hubbard. All rights reserved. @@ -254,6 +254,9 @@ installFixitCDROM(dialogMenuItem *self) { struct stat sb; + if (!RunningAsInit) + return DITEM_SUCCESS; + variable_set2(SYSTEM_STATE, "fixit"); (void)unlink("/mnt2"); (void)rmdir("/mnt2"); @@ -269,6 +272,8 @@ installFixitCDROM(dialogMenuItem *self) if (msgYesNo("Unable to mount the CDROM - do you want to try again?") != 0) return DITEM_FAILURE; } + else + break; } /* Since the fixit code expects everything to be in /mnt2, and the CDROM mounting stuff /cdrom, do @@ -323,6 +328,9 @@ installFixitFloppy(dialogMenuItem *self) { struct ufs_args args; + if (!RunningAsInit) + return DITEM_SUCCESS; + variable_set2(SYSTEM_STATE, "fixit"); memset(&args, 0, sizeof(args)); args.fspec = "/dev/fd0"; |