1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter-feeds.git synced 2025-02-12 10:31:51 +00:00

Add -w to iptables where missing

This commit is contained in:
Ycarus (Yannick Chabanois) 2021-03-25 16:24:14 +01:00
parent 6be97273d0
commit 21866054c6
2 changed files with 3 additions and 3 deletions

View file

@ -112,7 +112,7 @@ ss_rules_parse_args() {
__errmsg "Requires at least -l or -L option"
return 1
fi
if [ -n "$o_dst_forward_recentrst" ] && ! iptables -m recent -h >/dev/null; then
if [ -n "$o_dst_forward_recentrst" ] && ! iptables -w -m recent -h >/dev/null; then
__errmsg "Please install iptables-mod-conntrack-extra with opkg"
return 1
fi
@ -166,7 +166,7 @@ ss_rules_iptchains_init() {
}
ss_rules_iptchains_init_mark() {
if [ "$(iptables -t mangle -L PREROUTING | grep ss_rules_dst_bypass_all)" = "" ]; then
if [ "$(iptables -w -t mangle -L PREROUTING | grep ss_rules_dst_bypass_all)" = "" ]; then
iptables-restore -w --noflush <<-EOF
*mangle
-A PREROUTING -m set --match-set ss_rules_dst_bypass_all dst -j MARK --set-mark 0x539

View file

@ -95,7 +95,7 @@ ss_rules6_parse_args() {
__errmsg "Requires at least -l or -L option"
return 1
fi
if [ -n "$o_dst_forward_recentrst" ] && ! ip6tables -m recent -h >/dev/null; then
if [ -n "$o_dst_forward_recentrst" ] && ! ip6tables -w -m recent -h >/dev/null; then
__errmsg "Please install ip6tables-mod-conntrack-extra with opkg"
return 1
fi