mwan3: do not add mwan3_custom_v6 set if ipv6 is not available
authorFlorian Eckert <fe@dev.tdt.de>
Fri, 25 Feb 2022 11:04:57 +0000 (12:04 +0100)
committerFlorian Eckert <fe@dev.tdt.de>
Mon, 14 Mar 2022 08:34:49 +0000 (09:34 +0100)
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
net/mwan3/files/lib/mwan3/mwan3.sh

index e6f75334c2987567e09c89e3ad3ef3008844aee6..1dcb8aef593efecbd01cb2d9a2916ccda1f33e8e 100644 (file)
@@ -140,7 +140,7 @@ mwan3_set_custom_ipset()
 
        mwan3_push_update -! create mwan3_connected list:set
        mwan3_push_update -! add mwan3_connected mwan3_custom_v4
-       mwan3_push_update -! add mwan3_connected mwan3_custom_v6
+       [ $NO_IPV6 -eq 0 ] && mwan3_push_update -! add mwan3_connected mwan3_custom_v6
        error=$(echo "$update" | $IPS restore 2>&1) || LOG error "set_custom_ipset: $error"
 }