procd: options with default values are not parsed properly in the ubus register code
[openwrt/staging/yousong.git] / package / system / procd / files / procd.sh
index 7b8640ad727921a011e4d078fd09282dddf05123..d058c4ff5ea41bf5d4b9322a23c20b2c5386675b 100644 (file)
@@ -229,7 +229,8 @@ uci_validate_section()
                shift; shift; shift
 
                while [ -n "$1" ]; do
-                       json_add_string "${1%:*}" "${1#*:}"
+                       local tmp=${1#*:}
+                       json_add_string "${1%%:*}" "${tmp%%:*}"
                        shift
                done