Skip to content

Commit

Permalink
changed: With iptables4/6-tables-restore also filter legacy messages …
Browse files Browse the repository at this point in the history
…on stderr
  • Loading branch information
arnova committed Aug 2, 2023
1 parent d471f9d commit 2677020
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions share/arno-iptables-firewall/environment
Original file line number Diff line number Diff line change
Expand Up @@ -410,8 +410,8 @@ ip4tables_restore()

RULE_WARNING=$((RULE_WARNING + 1))
elif [ -n "$err_result" ]; then
# ip4tables_restore returned success, so normal output of stderr
echo "$err_result" >&2
# ip4tables_restore returned success, so normal output of stderr but filter some messages
echo "$err_result" |grep -v -e 'WARNING:.*match is obsolete' -e 'iptables-legacy tables present' >&2
fi

return $retval
Expand Down Expand Up @@ -454,8 +454,8 @@ ip6tables_restore()

RULE_WARNING=$((RULE_WARNING + 1))
elif [ -n "$err_result" ]; then
# ip6tables_restore returned success, so normal output of stderr
echo "$err_result" >&2
# ip6tables_restore returned success, so normal output of stderr but filter some messages
echo "$err_result" |grep -v -e 'WARNING:.*match is obsolete' -e 'iptables-legacy tables present' >&2
fi

return $retval
Expand Down

0 comments on commit 2677020

Please sign in to comment.