diff options
author | Mike Baker <mbm@openwrt.org> | 2005-05-06 08:09:51 +0000 |
---|---|---|
committer | Mike Baker <mbm@openwrt.org> | 2005-05-06 08:09:51 +0000 |
commit | 78d0b7803d0ed2e43c84f02fab9a8338c6cd95b2 (patch) | |
tree | 24b6986567d6a859fb28e7df30ae59583d9f9976 /openwrt | |
parent | d2b7e6b8bc45622faa4f8225fac4bcd5ad338095 (diff) | |
download | mtk-20170518-78d0b7803d0ed2e43c84f02fab9a8338c6cd95b2.zip mtk-20170518-78d0b7803d0ed2e43c84f02fab9a8338c6cd95b2.tar.gz mtk-20170518-78d0b7803d0ed2e43c84f02fab9a8338c6cd95b2.tar.bz2 |
wlcompat probe bugfix
SVN-Revision: 809
Diffstat (limited to 'openwrt')
-rw-r--r-- | openwrt/package/openwrt/wlcompat.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/openwrt/package/openwrt/wlcompat.c b/openwrt/package/openwrt/wlcompat.c index 74dcdf2..3c163fd 100644 --- a/openwrt/package/openwrt/wlcompat.c +++ b/openwrt/package/openwrt/wlcompat.c @@ -698,12 +698,10 @@ static int __init wlcompat_init() int found = 0, i; char *devname = "eth0"; - while (!found && devname[3] < '3') { - devname[3]++; - - dev = dev_get_by_name(devname); + while (!found && (dev = dev_get_by_name(devname))) { if ((wl_ioctl(dev, WLC_GET_MAGIC, &i, sizeof(i)) == 0) && i == WLC_IOCTL_MAGIC) found = 1; + devname[3]++; } if (!found) { |