From be2d0536f4f6083cc0ba77d4e70915164889ca3e Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Sun, 2 Dec 2018 14:29:53 +0100 Subject: [PATCH] luci-mod-status: use -w flag when dumping iptables Multiple iptables listing commands might be triggered in parallel due to the XHR polling, so use the -w flag to wait for the lock to become free. Signed-off-by: Jo-Philipp Wich --- modules/luci-mod-status/luasrc/controller/admin/status.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/luci-mod-status/luasrc/controller/admin/status.lua b/modules/luci-mod-status/luasrc/controller/admin/status.lua index 5b496d83f..63b939077 100644 --- a/modules/luci-mod-status/luasrc/controller/admin/status.lua +++ b/modules/luci-mod-status/luasrc/controller/admin/status.lua @@ -53,7 +53,7 @@ function dump_iptables(family, table) for s in lines do if s == table then local ipt = io.popen( - "/usr/sbin/%stables -t %s --line-numbers -nxvL" + "/usr/sbin/%stables -w -t %s --line-numbers -nxvL" %{ prefix, table }) if ipt then -- 2.25.1