summaryrefslogtreecommitdiffstats
path: root/net/wireless/scan.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2009-08-12 17:44:53 -0700
committerDavid S. Miller <davem@davemloft.net>2009-08-12 17:44:53 -0700
commitaa11d958d1a6572eda08214d7c6a735804fe48a5 (patch)
treed025b05270ad1e010660d17eeadc6ac3c1abbd7d /net/wireless/scan.c
parent07f6642ee9418e962e54cbc07471cfe2e559c568 (diff)
parent9799218ae36910af50f002a5db1802d576fffb43 (diff)
downloadop-kernel-dev-aa11d958d1a6572eda08214d7c6a735804fe48a5.zip
op-kernel-dev-aa11d958d1a6572eda08214d7c6a735804fe48a5.tar.gz
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts: arch/microblaze/include/asm/socket.h
Diffstat (limited to 'net/wireless/scan.c')
-rw-r--r--net/wireless/scan.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/net/wireless/scan.c b/net/wireless/scan.c
index 67714d7..0ccf3a0 100644
--- a/net/wireless/scan.c
+++ b/net/wireless/scan.c
@@ -141,7 +141,7 @@ static int cmp_ies(u8 num, u8 *ies1, size_t len1, u8 *ies2, size_t len2)
if (!ie1 && !ie2)
return 0;
- if (!ie1)
+ if (!ie1 || !ie2)
return -1;
r = memcmp(ie1 + 2, ie2 + 2, min(ie1[1], ie2[1]));
@@ -194,6 +194,8 @@ static bool is_mesh(struct cfg80211_bss *a,
ie = find_ie(WLAN_EID_MESH_CONFIG,
a->information_elements,
a->len_information_elements);
+ if (!ie)
+ return false;
if (ie[1] != IEEE80211_MESH_CONFIG_LEN)
return false;
OpenPOWER on IntegriCloud