Browse Source

mwan3: Fix json_load fails with some data

Sometimes the return value of `ubus -S call network.interface.wan status`
cause `json_load` to return `Failed to parse message data` error.

To avoid this, the JSON data always should be quoted with double quotes.

Signed-off-by: Evren Yurtesen <eyurtese@abo.fi>
Removed quoatation marks from commit heading
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
lilik-openwrt-22.03
yurtesen 5 years ago
committed by Florian Eckert
parent
commit
94e0c78826
2 changed files with 3 additions and 3 deletions
  1. +2
    -2
      net/mwan3/Makefile
  2. +1
    -1
      net/mwan3/files/usr/sbin/mwan3

+ 2
- 2
net/mwan3/Makefile View File

@ -8,8 +8,8 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=mwan3
PKG_VERSION:=2.8.0
PKG_RELEASE:=2
PKG_VERSION:=2.8.1
PKG_RELEASE:=1
PKG_MAINTAINER:=Florian Eckert <fe@dev.tdt.de>
PKG_LICENSE:=GPLv2


+ 1
- 1
net/mwan3/files/usr/sbin/mwan3 View File

@ -63,7 +63,7 @@ ifup()
status=$(ubus -S call network.interface.$1 status)
[ -n "$status" ] && {
json_load $status
json_load "$status"
json_get_vars up l3_device
}


Loading…
Cancel
Save