diff options
Diffstat (limited to 'rescue/restore-image.sh')
-rwxr-xr-x | rescue/restore-image.sh | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/rescue/restore-image.sh b/rescue/restore-image.sh index 3776f9222..a5021bdbd 100755 --- a/rescue/restore-image.sh +++ b/rescue/restore-image.sh @@ -93,14 +93,18 @@ function detect_root() else _msgbox "\nError writing image: disk device not detected.\n" fi - else - _msgbox "\nError writing image: disk device not detected.\n" fi } function write_image() { root=$(detect_root) + if [ -z ${root} ]; then + _msgbox "\nError writing image: disk device not detected.\n" + # so that netbooks using USB sticks as disks can retry (like Gdium) + welcome + fi + image=$(cat $images_dir/list | cut -d ',' -f 3) extension=$(echo $image | cut -d '.' -f 3) case $extension in |