From 608d41f64972697b7389678d63d1391daa2fab42 Mon Sep 17 00:00:00 2001 From: Jan Blunck Date: Mon, 2 Sep 2013 17:03:42 +0200 Subject: Move check for block device to mount_persistence_media(). We should only check for the persistence media path being a block device where it is really required which is the case in mount_persistence_media(). --- components/9990-misc-helpers.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'components') diff --git a/components/9990-misc-helpers.sh b/components/9990-misc-helpers.sh index 570a12a..c502d59 100755 --- a/components/9990-misc-helpers.sh +++ b/components/9990-misc-helpers.sh @@ -694,6 +694,11 @@ mount_persistence_media () device=${1} probe=${2} + if [ ! -b "${device}" ] + then + return 1 + fi + backing="/live/persistence/$(basename ${device})" mkdir -p "${backing}" @@ -1250,11 +1255,6 @@ get_custom_mounts () for device in ${devices} do - if [ ! -b "${device}" ] - then - continue - fi - local device_name backing include_list device_name="$(basename ${device})" backing=$(mount_persistence_media ${device}) -- cgit v1.2.3