mwan3: fix shellcheck warning SC2166
authorFlorian Eckert <fe@dev.tdt.de>
Tue, 14 Jul 2020 09:47:15 +0000 (11:47 +0200)
committerFlorian Eckert <fe@dev.tdt.de>
Mon, 27 Jul 2020 10:17:31 +0000 (12:17 +0200)
Replace -o boolean check with ||.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
(cherry picked from commit c0fdfaa17490f5e67bc24a326f10af1c7d0201cf)

net/mwan3/files/lib/mwan3/mwan3.sh

index 3c4f25cc4018142061aa19b018e1ad1a9739958c..6c8e5008005bad1e57e0b92d0b3bbdc4a2b6069e 100644 (file)
@@ -1067,7 +1067,7 @@ mwan3_report_iface_status()
                IPT="$IPT6"
        fi
 
-       if [ -z "$id" -o -z "$device" ]; then
+       if [ -z "$id" ] || [ -z "$device" ]; then
                result="offline"
        elif [ -n "$($IP rule | awk '$1 == "'$(($id+1000)):'"')" ] && \
                [ -n "$($IP rule | awk '$1 == "'$(($id+2000)):'"')" ] && \