ipv6-support: Add support for NPT status tracking
authorSteven Barth <cyrus@openwrt.org>
Mon, 10 Dec 2012 16:46:59 +0000 (16:46 +0000)
committerSteven Barth <cyrus@openwrt.org>
Mon, 10 Dec 2012 16:46:59 +0000 (16:46 +0000)
SVN-Revision: 34609

package/network/ipv6/ipv6-support/Makefile
package/network/ipv6/ipv6-support/files/support.sh

index 97bff4d08411a25badd5034b7c7290a806147f69..a814b52fb6454b605d188b725d14fe54938bd995 100644 (file)
@@ -8,7 +8,7 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=ipv6-support
-PKG_VERSION:=2012-12-08
+PKG_VERSION:=2012-12-10
 PKG_RELEASE:=1
 
 include $(INCLUDE_DIR)/package.mk
index 8a0e5404319e958c829c15e34613cf29c10fd0d8..8e8458b88840e8a8d7e4022ee7c944ee5f884cbc 100644 (file)
@@ -134,11 +134,12 @@ announce_prefix() {
        # Always announce the ULA when doing NPT
        [ "$prefix" == "$ula" -a "$prefix_action" == "npt" ] && prefix_action="distribute"
 
-       [ "$prefix_action" == "distribute" ] && {
+       [ "$prefix_action" == "distribute" -o "$prefix_action" == "npt" ] && {
                local msg='{"network": "'"$network"'", "prefix": "'"$addr"'", "length": '"$length"
                [ -n "$valid" ] && msg="$msg"', "valid": '"$valid"', "preferred": '"$prefer"
                [ -z "$cmd" ] && cmd=newprefix
-       
+
+               [ "$prefix_action" == "npt" ] && msg="$msg"', "npt": 1'
                ubus call 6distributed "$cmd" "$msg}"
        }