Include 'sys/sysmacros.h' for GCC-9
[platform/upstream/cryptsetup.git] / tests / mode-test
index 3801718..fcc460d 100755 (executable)
@@ -52,7 +52,7 @@ add_device() {
 dmcrypt_check() # device outstring
 {
        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]"
        else
                echo "[table FAIL]"
@@ -65,7 +65,7 @@ dmcrypt_check() # device outstring
                echo -n "[status OK]"
        else
                echo "[status FAIL]"
-               echo " Expecting $2 got $X."
+               echo " Expecting $2 got \"$X\"."
                fail
        fi