Skip to content

Commit

Permalink
Fixing find_snap to take its second argument into account.
Browse files Browse the repository at this point in the history
  • Loading branch information
intrigeri authored and daniel-baumann committed Sep 26, 2010
1 parent 967ed28 commit 94fed52
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions scripts/live
Expand Up @@ -1005,16 +1005,17 @@ find_snap ()
{
# Look for ${snap_label}.* in block devices
snap_label="${1}"
black_listed_devices="${2}"

if [ "${PERSISTENT}" != "nofiles" ]
then
# search for image files
snapdata=$(find_files "${PERSISTENT_PATH}${snap_label}.squashfs ${PERSISTENT_PATH}${snap_label}.cpio.gz ${PERSISTENT_PATH}${snap_label}.ext2 ${PERSISTENT_PATH}${snap_label}.ext3 ${PERSISTENT_PATH}${snap_label}.ext4 ${PERSISTENT_PATH}${snap_label}.jffs2")
snapdata=$(find_files "${PERSISTENT_PATH}${snap_label}.squashfs ${PERSISTENT_PATH}${snap_label}.cpio.gz ${PERSISTENT_PATH}${snap_label}.ext2 ${PERSISTENT_PATH}${snap_label}.ext3 ${PERSISTENT_PATH}${snap_label}.ext4 ${PERSISTENT_PATH}${snap_label}.jffs2" "${black_listed_devices}")
fi

if [ -z "${snapdata}" ]
then
snapdata=$(find_cow_device "${snap_label}")
snapdata=$(find_cow_device "${snap_label}" "${black_listed_devices}")
fi
echo "${snapdata}"
}
Expand Down

0 comments on commit 94fed52

Please sign in to comment.