Changeset 7565

Show
Ignore:
Timestamp:
09/26/11 00:08:47 (20 months ago)
Author:
jow
Message:

modules/admin-full: ... and another issue, also remove wifi up workaround, its done by "ifup" now

Location:
luci/trunk/modules/admin-full/luasrc
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • luci/trunk/modules/admin-full/luasrc/controller/admin/network.lua

    r7564 r7565  
    283283    local net = netmd:get_network(iface) 
    284284    if net then 
    285         local ifn 
    286         for _, ifn in ipairs(net:get_interfaces()) do 
    287             local wnet = ifn:get_wifinet() 
    288             if wnet then 
    289                 local wdev = wnet:get_device() 
    290                 if wdev then 
    291                     luci.sys.call( 
    292                         "env -i /sbin/wifi up %q >/dev/null 2>/dev/null" 
    293                             % wdev:name() 
    294                     ) 
    295  
    296                     luci.http.status(200, "Reconnected") 
    297                     return 
    298                 end 
    299             end 
    300         end 
    301  
    302285        luci.sys.call("env -i /sbin/ifup %q >/dev/null 2>/dev/null" % iface) 
    303286        luci.http.status(200, "Reconnected") 
  • luci/trunk/modules/admin-full/luasrc/model/cbi/admin_network/ifaces.lua

    r7503 r7565  
    158158        local old_ifs = { } 
    159159 
    160         for _, i in ipairs(n:get_interfaces()) do 
     160        for _, i in ipairs(n:get_interfaces() or { n:get_interface() }) do 
    161161            old_ifs[#old_ifs+1] = i:name() 
    162162        end