From 889d3a4111c9a5f501602b6387ce273e40e2b9db Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Tue, 23 Dec 2008 21:57:34 +0000 Subject: trunk: remove bitrot --- .../luci-coovachilli/luasrc/model/cbi/coovachilli_network.lua | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'applications/luci-coovachilli/luasrc/model/cbi') diff --git a/applications/luci-coovachilli/luasrc/model/cbi/coovachilli_network.lua b/applications/luci-coovachilli/luasrc/model/cbi/coovachilli_network.lua index e3351ab000..2e9768ff3d 100644 --- a/applications/luci-coovachilli/luasrc/model/cbi/coovachilli_network.lua +++ b/applications/luci-coovachilli/luasrc/model/cbi/coovachilli_network.lua @@ -28,14 +28,8 @@ s1:option( Value, "txqlen" ).optional = true net = s1:option( Value, "net" ) for _, route in ipairs(luci.sys.net.routes()) do - if route.Iface ~= "lo" and route.Mask ~= "FFFFFFFF" then - local netmask = luci.ip.IPv4(route.Mask) - if netmask then - local netaddr = luci.ip.IPv4(route.Destination, netmask) - if netaddr then - net:value( netaddr:string() ) - end - end + if route.device ~= "lo" and route.dest:prefix() < 32 then + net:value( route.dest:string() ) end end -- cgit v1.2.3