summaryrefslogtreecommitdiff
path: root/package/firewall/files/lib/config.sh
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2010-05-31 01:34:47 +0000
committerJo-Philipp Wich <jow@openwrt.org>2010-05-31 01:34:47 +0000
commita756114e593fe2c287c46f75f4bff6e8bc363ebf (patch)
treed826818c5552b4b97fb35d8a2fa6e23891028699 /package/firewall/files/lib/config.sh
parentc14e8be3378e159a3fef9aa561f91ce5c671e266 (diff)
downloadmtk-20170518-a756114e593fe2c287c46f75f4bff6e8bc363ebf.zip
mtk-20170518-a756114e593fe2c287c46f75f4bff6e8bc363ebf.tar.gz
mtk-20170518-a756114e593fe2c287c46f75f4bff6e8bc363ebf.tar.bz2
firewall: change the order of IPv4/IPv6 address detection, fixes mixed notation v6 improperly detected as v4 address
SVN-Revision: 21642
Diffstat (limited to 'package/firewall/files/lib/config.sh')
-rw-r--r--package/firewall/files/lib/config.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/package/firewall/files/lib/config.sh b/package/firewall/files/lib/config.sh
index c213912..996cef8 100644
--- a/package/firewall/files/lib/config.sh
+++ b/package/firewall/files/lib/config.sh
@@ -87,8 +87,8 @@ config_get_ipaddr() {
local vers=
case "$addr" in
- *.*) vers=4; mask="${mask:-32}" ;;
*:*) vers=6; mask="${mask:-128}" ;;
+ *.*) vers=4; mask="${mask:-32}" ;;
esac
export ${NO_EXPORT:+-n} -- "${varn}=${addr}"