OSDN Git Service

Fix: empty mount options
authornatemaia <natemaia10@gmail.com>
Sun, 16 Dec 2018 07:47:14 +0000 (23:47 -0800)
committernatemaia <natemaia10@gmail.com>
Sun, 17 Mar 2019 04:21:48 +0000 (21:21 -0700)
src/lib/mount.sh
src/lib/part.sh

index 5d918ae..a3ddbd6 100644 (file)
@@ -107,13 +107,14 @@ select_mount_opts()
 
     tput civis
     if ! MNT_OPTS="$(dialog --cr-wrap --stdout --backtitle "$BT" --title " $title " \
-        --checklist "$_MntBody" 0 0 0 $opts | sed 's/ /,/g; $s/,$//')"; then
+        --checklist "$_MntBody" 0 0 0 $opts | sed 's/ /,/g; $s/,$//')" || [[ $MNT_OPTS == "" ]]; then
         return 1
     fi
 
     if ! yesno "$title" "$_MntConfBody $MNT_OPTS\n"; then
         select_mount_opts "$part" "$fs" || return 1
     fi
+
     return 0
 }
 
index 49aaacb..d0b4044 100644 (file)
@@ -225,7 +225,6 @@ auto_partition()
     # confirm or bail
     yesno "$_PrepParts" "$_PartBody1 $device $msg ($size)$_PartBody3" || return 0
     infobox "$_PrepParts" "\nRemoving existing partitions on $device and setting partition table to $table\n" 1
-
     swapoff -a  # in case the device was previously used for swap
 
     local dev_info