summaryrefslogtreecommitdiff
path: root/components
diff options
context:
space:
mode:
authorJan Blunck <jblunck@vyatta.com>2013-09-02 17:03:42 +0200
committerDaniel Baumann <mail@daniel-baumann.ch>2013-09-13 14:15:48 +0200
commit608d41f64972697b7389678d63d1391daa2fab42 (patch)
treea8b15e3d0e91d7e5e73d4dbfc02242159e3ac402 /components
parent25cc091826ff32e5b1e33fe668fe273bec59724c (diff)
downloadlive-boot-608d41f64972697b7389678d63d1391daa2fab42.tar.gz
live-boot-608d41f64972697b7389678d63d1391daa2fab42.zip
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().
Diffstat (limited to 'components')
-rwxr-xr-xcomponents/9990-misc-helpers.sh10
1 files changed, 5 insertions, 5 deletions
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})