summaryrefslogtreecommitdiff
path: root/templates/protocols
diff options
context:
space:
mode:
authorDmitriyEshenko <dmitriy.eshenko@vyos.io>2022-01-19 13:04:07 +0000
committerDmitriyEshenko <dmitriy.eshenko@vyos.io>2022-01-19 13:04:07 +0000
commit8ac75ae86c54fb931d6e61320b7b973eaa1841c5 (patch)
tree12d8553129d0bc48b134327aebf4dd96b15b5513 /templates/protocols
parent32cbb1e5059c6c27449b7013f790aff1c50a9831 (diff)
downloadvyatta-cfg-quagga-8ac75ae86c54fb931d6e61320b7b973eaa1841c5.tar.gz
vyatta-cfg-quagga-8ac75ae86c54fb931d6e61320b7b973eaa1841c5.zip
T3522: Use printf to get hex instead of dc
Diffstat (limited to 'templates/protocols')
-rw-r--r--templates/protocols/static/table/node.tag/route/node.tag/dhcp-interface/node.def6
1 files changed, 3 insertions, 3 deletions
diff --git a/templates/protocols/static/table/node.tag/route/node.tag/dhcp-interface/node.def b/templates/protocols/static/table/node.tag/route/node.tag/dhcp-interface/node.def
index 3f0afdb1..6f8adb31 100644
--- a/templates/protocols/static/table/node.tag/route/node.tag/dhcp-interface/node.def
+++ b/templates/protocols/static/table/node.tag/route/node.tag/dhcp-interface/node.def
@@ -17,7 +17,7 @@ create:
if [ "$route" == "0.0.0.0/0" ]; then
LIP=$(/opt/vyatta/sbin/vyatta-dhcp-helper.pl --interface=$ifc --want=local)
if [ "$LIP" != "127.0.0.1" ]; then
- MARK=$(dc 0x7fffffff $table + p)
+ MARK=`printf "0x%x" $((2147483647+$table))`
sudo /sbin/iptables -t mangle -I OUTPUT -s $LIP/32 -j MARK --set-mark $MARK
fi
fi
@@ -34,7 +34,7 @@ update:
if [ "$route" == "0.0.0.0/0" ]; then
LIP=$(/opt/vyatta/sbin/vyatta-dhcp-helper.pl --interface=$ifc --want=local)
if [ "$LIP" != "127.0.0.1" ]; then
- MARK=$(dc 0x7fffffff $table + p)
+ MARK=`printf "0x%x" $((2147483647+$table))`
sudo /sbin/iptables -t mangle -I OUTPUT -s $LIP/32 -j MARK --set-mark $MARK
fi
fi
@@ -51,7 +51,7 @@ delete:
if [ "$route" == "0.0.0.0/0" ]; then
LIP=$(/opt/vyatta/sbin/vyatta-dhcp-helper.pl --interface=$ifc --want=local)
if [ "$LIP" != "127.0.0.1" ]; then
- MARK=$(dc 0x7fffffff $table + p)
+ MARK=`printf "0x%x" $((2147483647+$table))`
sudo /sbin/iptables -t mangle -D OUTPUT -s $LIP/32 -j MARK --set-mark $MARK
fi
fi