Lines 74-84
Link Here
|
74 |
# $2 = recognition file |
74 |
# $2 = recognition file |
75 |
# $3 = variable to have the device path |
75 |
# $3 = variable to have the device path |
76 |
# $4 = directory before /mnt, like NEW_ROOT |
76 |
# $4 = directory before /mnt, like NEW_ROOT |
|
|
77 |
# $5 = mount type for devices |
77 |
# args remaining are possible devices |
78 |
# args remaining are possible devices |
78 |
|
79 |
|
79 |
local media=$1 recon=$2 vrbl=$3 |
80 |
(( $# < 6 )) && \ |
|
|
81 |
bad_msg "Bad invocation of function findmediamount, please file a bug \ |
82 |
report with this message" && exit 1 |
83 |
|
84 |
local media=$1 recon=$2 vrbl=$3 mnttype=$5 |
80 |
local mntdir="${4}/mnt/${media}" |
85 |
local mntdir="${4}/mnt/${media}" |
81 |
shift 4 |
86 |
shift 5 |
82 |
|
87 |
|
83 |
good_msg "Looking for the ${media}" ${CRYPT_SILENT} |
88 |
good_msg "Looking for the ${media}" ${CRYPT_SILENT} |
84 |
|
89 |
|
Lines 94-105
Link Here
|
94 |
then |
99 |
then |
95 |
good_msg "Attempting to mount media:- ${x}" ${CRYPT_SILENT} |
100 |
good_msg "Attempting to mount media:- ${x}" ${CRYPT_SILENT} |
96 |
|
101 |
|
97 |
# if [ "${media}" = "cdrom" ]; then |
102 |
mount -r -t ${mnttype} ${x} ${mntdir} >/dev/null 2>&1 |
98 |
# mount -r -t iso9660 ${x} ${mntdir} &>/dev/null |
103 |
|
99 |
# else |
|
|
100 |
# mount -r -t auto ${x} ${mntdir} &>/dev/null |
101 |
# fi |
102 |
mount -r -t ${CDROOT_TYPE} ${x} ${mntdir} &>/dev/null |
103 |
if [ "$?" = '0' ] |
104 |
if [ "$?" = '0' ] |
104 |
then |
105 |
then |
105 |
# Check for the media |
106 |
# Check for the media |
Lines 143-149
Link Here
|
143 |
# a bunch of extra devices |
144 |
# a bunch of extra devices |
144 |
[ -n "${CDROOT_DEV}" ] && DEVICES="${CDROOT_DEV}" |
145 |
[ -n "${CDROOT_DEV}" ] && DEVICES="${CDROOT_DEV}" |
145 |
|
146 |
|
146 |
findmediamount "cdrom" "${SUBDIR}/livecd" "REAL_ROOT" "${NEW_ROOT}" ${DEVICES} |
147 |
findmediamount "cdrom" "${SUBDIR}/livecd" "REAL_ROOT" "${NEW_ROOT}" "${CDROOT_TYPE}" ${DEVICES} |
147 |
} |
148 |
} |
148 |
|
149 |
|
149 |
bootstrapKey() { |
150 |
bootstrapKey() { |
Lines 151-157
Link Here
|
151 |
local KEYDEVS=`devicelist` |
152 |
local KEYDEVS=`devicelist` |
152 |
eval local keyloc='"${CRYPT_'${1}'_KEY}"' |
153 |
eval local keyloc='"${CRYPT_'${1}'_KEY}"' |
153 |
|
154 |
|
154 |
findmediamount "key" "${keyloc}" "CRYPT_${1}_KEYDEV" "" ${KEYDEVS} |
155 |
findmediamount "key" "${keyloc}" "CRYPT_${1}_KEYDEV" "" "auto" ${KEYDEVS} |
155 |
} |
156 |
} |
156 |
|
157 |
|
157 |
cache_cd_contents() { |
158 |
cache_cd_contents() { |