diff options
author | Jo-Philipp Wich <jow@openwrt.org> | 2010-09-16 11:47:35 +0000 |
---|---|---|
committer | Jo-Philipp Wich <jow@openwrt.org> | 2010-09-16 11:47:35 +0000 |
commit | f90328f26ef73fc5a0c2d9a751936e9af060ccba (patch) | |
tree | 8b43a2a7814861c1265ad9747419d8ad19be6c9f /package/firewall/files/lib/core.sh | |
parent | 4df10391ba87d347aebbcd20e1ab475690f07f80 (diff) | |
download | mtk-20170518-f90328f26ef73fc5a0c2d9a751936e9af060ccba.zip mtk-20170518-f90328f26ef73fc5a0c2d9a751936e9af060ccba.tar.gz mtk-20170518-f90328f26ef73fc5a0c2d9a751936e9af060ccba.tar.bz2 |
firewall: make invalid redirects and duplicate zones non-fatal, print a notice and discard them
SVN-Revision: 23080
Diffstat (limited to 'package/firewall/files/lib/core.sh')
-rw-r--r-- | package/firewall/files/lib/core.sh | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/package/firewall/files/lib/core.sh b/package/firewall/files/lib/core.sh index c350e8f..c383597 100644 --- a/package/firewall/files/lib/core.sh +++ b/package/firewall/files/lib/core.sh @@ -107,10 +107,8 @@ fw_die() { fw_log() { local level="$1" - [ -n "$2" ] || { - shift - level=notice - } + [ -n "$2" ] && shift || level=notice + [ "$level" != error ] || echo "Error: $@" >&2 logger -t firewall -p user.$level "$@" } |