mirror of
https://gitlab.com/cryptsetup/cryptsetup.git
synced 2025-12-17 13:50:06 +01:00
Seems that dmsetup table is broken in recent lvm2, let's support "x: table" as well.
git-svn-id: https://cryptsetup.googlecode.com/svn/trunk@551 36d66b0a-2a48-0410-832c-cd162a569da5
This commit is contained in:
@@ -51,7 +51,7 @@ add_device() {
|
|||||||
|
|
||||||
dmcrypt_check() # device outstring
|
dmcrypt_check() # device outstring
|
||||||
{
|
{
|
||||||
X=$(dmsetup table $1 2>/dev/null | cut -d' ' -f 4)
|
X=$(dmsetup table $1 2>/dev/null | sed 's/.*: //' | cut -d' ' -f 4)
|
||||||
if [ $X = $2 ] ; then
|
if [ $X = $2 ] ; then
|
||||||
echo -n "[table OK]"
|
echo -n "[table OK]"
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ crypt_key() # hash keysize pwd/file name outkey [limit]
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
VKEY=$(dmsetup table $DEV2 --showkeys 2>/dev/null | cut -d' ' -f 5)
|
VKEY=$(dmsetup table $DEV2 --showkeys 2>/dev/null | sed 's/.*: //' | cut -d' ' -f 5)
|
||||||
if [ "$VKEY" != "$5" ] ; then
|
if [ "$VKEY" != "$5" ] ; then
|
||||||
echo " [FAILED]"
|
echo " [FAILED]"
|
||||||
echo "expected: $5"
|
echo "expected: $5"
|
||||||
|
|||||||
Reference in New Issue
Block a user