modules/admin-full: fix removal of wireless networks if radio is disabled
authorJo-Philipp Wich <jow@openwrt.org>
Mon, 5 Dec 2011 19:34:47 +0000 (19:34 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Mon, 5 Dec 2011 19:34:47 +0000 (19:34 +0000)
modules/admin-full/luasrc/controller/admin/network.lua

index 24f17e9..a298443 100644 (file)
@@ -216,14 +216,14 @@ function wifi_delete(network)
                local dev = wnet:get_device()
                local net = wnet:get_network()
                if dev then
-                       luci.sys.call("env -i /sbin/wifi down %q" % dev:name())
+                       luci.sys.call("env -i /sbin/wifi down %q >/dev/null" % dev:name())
                        ntm:del_wifinet(network)
                        ntm:commit("wireless")
                        if net:is_empty() then
                                ntm:del_network(net:name())
                                ntm:commit("network")
                        end
-                       luci.sys.call("env -i /sbin/wifi up %q" % dev:name())
+                       luci.sys.call("env -i /sbin/wifi up %q >/dev/null" % dev:name())
                end
        end