[brcm-2.4] fix wrong numbering of interfaces in wireless detection
authorJo-Philipp Wich <jow@openwrt.org>
Thu, 4 Feb 2010 17:11:56 +0000 (17:11 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Thu, 4 Feb 2010 17:11:56 +0000 (17:11 +0000)
SVN-Revision: 19525

package/broadcom-wl/files/lib/wifi/broadcom.sh

index 75f8b08..c444ce8 100644 (file)
@@ -335,9 +335,9 @@ EOF
 
 
 detect_broadcom() {
-       local i=0
+       local i=-1
 
-       while [ -f /proc/net/wl$((i++)) ]; do
+       while [ -f /proc/net/wl$((++i)) ]; do
                config_get type wl${i} type
                [ "$type" = broadcom ] && continue
                cat <<EOF