diff options
author | Olivier Blin <oblin@mandriva.com> | 2009-02-11 14:30:17 +0000 |
---|---|---|
committer | Olivier Blin <oblin@mandriva.com> | 2009-02-11 14:30:17 +0000 |
commit | 63d58dd063b4565724f0b252bef30ec5ae3a4b6b (patch) | |
tree | e94da2ff4c224826269d99e94600dfa63e60d8a6 | |
parent | a7c2862517cdd11f670f7c5dc8381883cb1e3083 (diff) | |
download | drakx-63d58dd063b4565724f0b252bef30ec5ae3a4b6b.tar drakx-63d58dd063b4565724f0b252bef30ec5ae3a4b6b.tar.gz drakx-63d58dd063b4565724f0b252bef30ec5ae3a4b6b.tar.bz2 drakx-63d58dd063b4565724f0b252bef30ec5ae3a4b6b.tar.xz drakx-63d58dd063b4565724f0b252bef30ec5ae3a4b6b.zip |
add new_win32_size variable
-rwxr-xr-x | rescue/restore-image.sh | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/rescue/restore-image.sh b/rescue/restore-image.sh index 7aac5c74e..c8b32f628 100755 --- a/rescue/restore-image.sh +++ b/rescue/restore-image.sh @@ -145,6 +145,8 @@ function detect_and_resize_win32() used=$(echo ${size} | awk '{ print $3 }') left=$(echo ${size} | awk '{ print $4 }') avail=$((${left}/2)) + # our install takes half of 'left' + new_win32_size=$(($((${used}+${avail}))*2)) if [ ! ${avail} -lt ${MIN_DISKSIZE} ]; then # get the next partition integer @@ -157,8 +159,8 @@ function detect_and_resize_win32() hpfs) device_id=87 ;; esac - # wrapper around libdrakx by blino (it takes half of 'left') - diskdrake-resize ${device} ${device_type} $(($((${used}+${avail}))*2)) &>/dev/null + # wrapper around libdrakx by blino + diskdrake-resize ${device} ${device_type} ${new_win32_size} &>/dev/null # we need some free sector here, rebuilding layout fdisk /dev/${disk} &>/dev/null <<EOF |