]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
multipathd: fix the comparison
authorLukas Nykryn <lnykryn@redhat.com>
Fri, 27 Nov 2020 08:32:20 +0000 (09:32 +0100)
committerDaniel Molkentin <daniel@molkentin.de>
Fri, 27 Nov 2020 09:00:03 +0000 (10:00 +0100)
From shellcheck:
/usr/lib/dracut/modules.d/90multipath/multipathd.sh:3:32: warning[SC2039]: In POSIX sh, == in place of = is undefined.
/usr/lib/dracut/modules.d/90multipath/multipathd.sh:3:32: warning[SC2193]: The arguments to this comparison can never be equal.

modules.d/90multipath/multipathd.sh

index 936c5dc7321bb4d84a55df85b3874d61496cd0b2..b0183ffeb663133c4c368ffc5bd0c70b09e9fee4 100755 (executable)
@@ -1,6 +1,6 @@
 #!/bin/sh
 
-if [ "$(getarg rd.multipath)x" == "default" ] && [ ! -e /etc/multipath.conf ]; then
+if [ "$(getarg rd.multipath)= "default" ] && [ ! -e /etc/multipath.conf ]; then
     mkdir -p /etc/multipath/multipath.conf.d
     mpathconf --enable
 fi