summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEyal Shapira <eyal@wizery.com>2011-12-07 10:37:04 (GMT)
committerLuciano Coelho <coelho@ti.com>2011-12-08 10:32:40 (GMT)
commit1b04b739f4c1d053bebb29657fb69bf03f180a97 (patch)
tree4d68463d1fcb92a41c6a644938304f40f97e9961
parent3dbb5846db1f5df3619b927cc2a7dcaf65a38f1e (diff)
downloadlinux-1b04b739f4c1d053bebb29657fb69bf03f180a97.tar.xz
wl12xx: minor fix in sched_scan_ssid_list
The user can pass broadcast SSID (ssid="") in the list of SSIDs for active scan. In this case the loop was attempting to match SSIDs in the filter list to this empty entry and marking them as HIDDEN (sending probe request) by mistake Signed-off-by: Eyal Shapira <eyal@wizery.com> Signed-off-by: Luciano Coelho <coelho@ti.com>
-rw-r--r--drivers/net/wireless/wl12xx/scan.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/wireless/wl12xx/scan.c b/drivers/net/wireless/wl12xx/scan.c
index 330d678..8599dab 100644
--- a/drivers/net/wireless/wl12xx/scan.c
+++ b/drivers/net/wireless/wl12xx/scan.c
@@ -572,6 +572,9 @@ wl12xx_scan_sched_scan_ssid_list(struct wl1271 *wl,
* so they're used in probe requests.
*/
for (i = 0; i < req->n_ssids; i++) {
+ if (!req->ssids[i].ssid_len)
+ continue;
+
for (j = 0; j < cmd->n_ssids; j++)
if (!memcmp(req->ssids[i].ssid,
cmd->ssids[j].ssid,