From f7fd32b9e54f775603ef9e81c0702ed21716a700 Mon Sep 17 00:00:00 2001 From: Ben Gras Date: Mon, 12 Sep 2005 13:25:40 +0000 Subject: [PATCH] at: first wipe partition table (workaround for a partition() bug) setup: steps fix --- commands/scripts/setup.sh | 14 ++++++++++---- drivers/at_wini/at_wini.c | 2 ++ 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/commands/scripts/setup.sh b/commands/scripts/setup.sh index 3e939a559..c7027b81f 100755 --- a/commands/scripts/setup.sh +++ b/commands/scripts/setup.sh @@ -319,6 +319,7 @@ while [ "$confirm" = "" ] do auto="" echo "" +echo " --- Step 4: Reinstall choice ------------------------------------------" if mount -r /dev/$home $TMPMP >/dev/null 2>&1 then umount /dev/$home >/dev/null 2>&1 echo "" @@ -334,7 +335,10 @@ do [Ff]*) confirm="ok"; auto="" ;; esac - else confirm="ok"; + else echo "" + echo "No old /home found. Doing full install." + echo "" + confirm="ok"; fi done @@ -343,6 +347,8 @@ nohome="0" if [ ! "$auto" = r ] then homesize="" +echo "" +echo " --- Step 5: /home configuration ---------------------------------------" while [ -z "$homesize" ] do @@ -387,7 +393,7 @@ blockdefault=4 if [ ! "$auto" = "r" ] then echo "" - echo " --- Step 4: Select a block size ---------------------------------------" +echo " --- Step 6: Select a block size ---------------------------------------" echo "" echo "The maximum (and default) file system block size is $blockdefault KB." @@ -439,7 +445,7 @@ echo "Creating /dev/$usr for /usr .." mkfs -B $blocksizebytes /dev/$usr || exit echo "" -echo " --- Step 5: Wait for bad block detection ------------------------------" +echo " --- Step 7: Wait for bad block detection ------------------------------" echo "" echo "Scanning disk for bad blocks. Hit CTRL+C to stop the scan if you are" echo "sure that there can not be any bad blocks. Otherwise just wait." @@ -466,7 +472,7 @@ readall -b /dev/$usr | sh trap 2 echo "" -echo " --- Step 6: Wait for files to be copied -------------------------------" +echo " --- Step 8: Wait for files to be copied -------------------------------" echo "" echo "This is the final step of the MINIX 3 setup. All files will be now be" echo "copied to your hard disk. This may take a while." diff --git a/drivers/at_wini/at_wini.c b/drivers/at_wini/at_wini.c index 34402e267..deddac695 100644 --- a/drivers/at_wini/at_wini.c +++ b/drivers/at_wini/at_wini.c @@ -538,6 +538,8 @@ message *m_ptr; #endif /* Partition the disk. */ + memset(wn->part, sizeof(wn->part), 0); + memset(wn->subpart, sizeof(wn->subpart), 0); partition(&w_dtab, w_drive * DEV_PER_DRIVE, P_PRIMARY, wn->state & ATAPI); } wn->open_ct++; -- 2.44.0