diff options
author | jkh <jkh@FreeBSD.org> | 1997-01-15 07:28:25 +0000 |
---|---|---|
committer | jkh <jkh@FreeBSD.org> | 1997-01-15 07:28:25 +0000 |
commit | 733cd98f4308df89a8867b3feaf155aba6c97698 (patch) | |
tree | 7f807771266b679361b3e18caf5554357799fb4c /usr.sbin/sysinstall/installUpgrade.c | |
parent | ff123f1d694131b75b3325b587541eb503882b72 (diff) | |
download | FreeBSD-src-733cd98f4308df89a8867b3feaf155aba6c97698.zip FreeBSD-src-733cd98f4308df89a8867b3feaf155aba6c97698.tar.gz |
Make upgrade allow reselection of failed media.
Diffstat (limited to 'usr.sbin/sysinstall/installUpgrade.c')
-rw-r--r-- | usr.sbin/sysinstall/installUpgrade.c | 26 |
1 files changed, 14 insertions, 12 deletions
diff --git a/usr.sbin/sysinstall/installUpgrade.c b/usr.sbin/sysinstall/installUpgrade.c index 09c73e9..064ffff 100644 --- a/usr.sbin/sysinstall/installUpgrade.c +++ b/usr.sbin/sysinstall/installUpgrade.c @@ -221,14 +221,17 @@ installUpgrade(dialogMenuItem *self) if (!mediaVerify()) { msgConfirm("Now you must specify an installation medium for the upgrade."); +media: if (!dmenuOpenSimple(&MenuMedia, FALSE) || !mediaDevice) return DITEM_FAILURE | DITEM_RECREATE; } if (!mediaDevice->init(mediaDevice)) { - msgConfirm("Couldn't initialize the media; upgrade aborted. Please\n" - "fix whatever the problem is and try again."); - return DITEM_FAILURE | DITEM_REDRAW; + if (!msgYesNo("Couldn't initialize the media. Would you like\n" + "to adjust your media selection and try again?")) + goto media; + else + return DITEM_FAILURE | DITEM_REDRAW; } if (RunningAsInit) { @@ -274,18 +277,17 @@ installUpgrade(dialogMenuItem *self) variable_unset(DISK_PARTITIONED); return DITEM_FAILURE | DITEM_RECREATE; } - } - if (DITEM_STATUS(chroot("/mnt")) == DITEM_FAILURE) { - msgConfirm("Unable to chroot to /mnt - something is wrong with the\n" - "root partition or the way it's mounted if this doesn't work."); - variable_unset(DISK_PARTITIONED); - return DITEM_FAILURE | DITEM_RECREATE; + if (DITEM_STATUS(chroot("/mnt")) == DITEM_FAILURE) { + msgConfirm("Unable to chroot to /mnt - something is wrong with the\n" + "root partition or the way it's mounted if this doesn't work."); + variable_unset(DISK_PARTITIONED); + return DITEM_FAILURE | DITEM_RECREATE; + } + chdir("/"); + systemCreateHoloshell(); } - chdir("/"); - systemCreateHoloshell(); - saved_etc = NULL; if (extractingBin) { while (!saved_etc) { |