diff --git a/automount.sh b/automount.sh index 3cd94ca..a739248 100755 --- a/automount.sh +++ b/automount.sh @@ -165,13 +165,10 @@ case ${2} in | while read DEV PROVIDER MNT do TARGET=$( mount | grep -E "^${PROVIDER} " | awk '{print $3}' ) - [ -z ${TARGET} ] && { - __state_remove ${MNT} ${STATE} - continue - } + __state_remove ${MNT} ${STATE} + [ -z ${TARGET} ] && continue umount -f ${TARGET} & unset TARGET - __state_remove ${MNT} ${STATE} __log "${DEV}:umount" done __state_unlock