olsr: smartfw: fix a syntax error whwile checking for 'nowan'
authorBastian Bittorf <bb@npl.de>
Sun, 12 Feb 2017 19:22:23 +0000 (20:22 +0100)
committerBastian Bittorf <bb@npl.de>
Sun, 12 Feb 2017 19:23:25 +0000 (20:23 +0100)
introduced in 059b26c2 in 2011-nov-14 ("Manuel Munz freifunk@somakoma.de modified init
file of olsrd with improvements for 6and4 operation and also for setup of smartgw")

olsrd/files/olsrd.init

index f5b866093f789b76331518852123077eff9059e9..48ca2815014ec80212cdb2703e212928d4d5dd6f 100644 (file)
@@ -717,7 +717,7 @@ olsrd_setup_smartgw_rules() {
                                $IP4T -I forwarding_rule -o tnl_+ -j ACCEPT
                                $IP4T -t nat -I postrouting_rule -o tnl_+ -j MASQUERADE
                                # Allow forwarding from tunl0 to (all) wan-interfaces
-                               if [ "$nowan"="0" ]; then
+                               if [ "$nowan" = '0' ]; then
                                        for IFACE in $wanifnames; do
                                                $IP4T -A forwarding_rule -i tunl0 -o $IFACE -j ACCEPT
                                        done
@@ -728,7 +728,7 @@ olsrd_setup_smartgw_rules() {
                                done
                        elif [ "$smartgatewayuplink" = "ipv6" ]; then
                                $IP6T -I forwarding_rule -o tnl_+ -j ACCEPT
-                               if [ "$nowan"="0" ]; then
+                               if [ "$nowan" = '0' ]; then
                                        for IFACE in $wanifnames; do
                                                $IP6T -A forwarding_rule -i tunl0 -o $IFACE -j ACCEPT
                                        done
@@ -740,7 +740,7 @@ olsrd_setup_smartgw_rules() {
                                $IP4T -t nat -I postrouting_rule -o tnl_+ -j MASQUERADE
                                for IPT in $IP4T $IP6T; do
                                        $IPT -I forwarding_rule -o tnl_+ -j ACCEPT
-                                       if [ "$nowan"="0" ]; then
+                                       if [ "$nowan" = '0' ]; then
                                                for IFACE in $wanifnames; do
                                                        $IPT -A forwarding_rule -i tunl0 -o $IFACE -j ACCEPT
                                                done