[package] base-files: properly handle wifi ifaces with no network attached, useful...
authorJo-Philipp Wich <jow@openwrt.org>
Tue, 8 Nov 2011 14:42:58 +0000 (14:42 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Tue, 8 Nov 2011 14:42:58 +0000 (14:42 +0000)
SVN-Revision: 28860

package/base-files/Makefile
package/base-files/files/sbin/wifi

index c3b03508893a9b9c428a2169f119cb1f6c7721a4..2b1cfa13b3e9349f9aa9f298049be232a12a114a 100644 (file)
@@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk
 include $(INCLUDE_DIR)/kernel.mk
 
 PKG_NAME:=base-files
-PKG_RELEASE:=88
+PKG_RELEASE:=89
 
 PKG_FILE_DEPENDS:=$(PLATFORM_DIR)/ $(GENERIC_PLATFORM_DIR)/base-files/
 PKG_BUILD_DEPENDS:=opkg/host
index 2e66bfcbe8d113accdf911c2dd0423d2bed95be5..5cbf50b5f5eae06ef95c3bfc0194d8fe41937bb2 100755 (executable)
@@ -129,9 +129,11 @@ start_net() {(
        local vifmac="$3"
 
        [ -f "/var/run/$iface.pid" ] && kill "$(cat /var/run/${iface}.pid)" 2>/dev/null
-       include /lib/network
-       scan_interfaces
-       setup_interface "$iface" "$config" "" "$vifmac"
+       [ -z "$config" ] || {
+               include /lib/network
+               scan_interfaces
+               setup_interface "$iface" "$config" "" "$vifmac"
+       }
 )}
 
 set_wifi_up() {