jshn: improve performance by using let instead of $(( ))
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
This commit is contained in:
parent
d133da5562
commit
d5d384b0ba
1 changed files with 1 additions and 1 deletions
|
@ -42,7 +42,7 @@ _json_inc() {
|
||||||
# var=$1
|
# var=$1
|
||||||
# dest=$2
|
# dest=$2
|
||||||
|
|
||||||
eval "${JSON_PREFIX}$1=\$(( \${${JSON_PREFIX}$1:-0} + 1))${2:+; $2=\"\$${JSON_PREFIX}$1\"}"
|
let "${JSON_PREFIX}$1 += 1" "$2 = ${JSON_PREFIX}$1"
|
||||||
}
|
}
|
||||||
|
|
||||||
_json_add_generic() {
|
_json_add_generic() {
|
||||||
|
|
Loading…
Reference in a new issue