Only try to attach if parent device actually exists.

I used ugly "/dev/${parent}" instead of "${parentdev}", because "/dev/"
prefix for devices listed in gbde_devices variable is optional.

Reported by:	Sean McNeil <sean@mcneil.com>
This commit is contained in:
Pawel Jakub Dawidek 2004-10-07 06:00:06 +00:00
parent cf0684ae6f
commit 58a038b845

View File

@ -82,7 +82,7 @@ gbde_start()
parentdev=${device%.bde}
parent=${parentdev#/dev/}
eval "lock=\${gbde_lock_${parent}-\"${gbde_lockdir}/${parent}.lock\"}"
if [ ! -e "${device}" ]; then
if [ -e "/dev/${parent}" -a ! -e "${device}" ]; then
echo "Configuring Disk Encryption for ${device}."
count=1