diff options
Diffstat (limited to 'net/wireless/scan.c')
-rw-r--r-- | net/wireless/scan.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/net/wireless/scan.c b/net/wireless/scan.c index f8e71b300001..7e595ce24eeb 100644 --- a/net/wireless/scan.c +++ b/net/wireless/scan.c | |||
@@ -35,8 +35,6 @@ void cfg80211_scan_done(struct cfg80211_scan_request *request, bool aborted) | |||
35 | else | 35 | else |
36 | nl80211_send_scan_done(wiphy_to_dev(request->wiphy), dev); | 36 | nl80211_send_scan_done(wiphy_to_dev(request->wiphy), dev); |
37 | 37 | ||
38 | wiphy_to_dev(request->wiphy)->scan_req = NULL; | ||
39 | |||
40 | #ifdef CONFIG_WIRELESS_EXT | 38 | #ifdef CONFIG_WIRELESS_EXT |
41 | if (!aborted) { | 39 | if (!aborted) { |
42 | memset(&wrqu, 0, sizeof(wrqu)); | 40 | memset(&wrqu, 0, sizeof(wrqu)); |
@@ -48,6 +46,7 @@ void cfg80211_scan_done(struct cfg80211_scan_request *request, bool aborted) | |||
48 | dev_put(dev); | 46 | dev_put(dev); |
49 | 47 | ||
50 | out: | 48 | out: |
49 | wiphy_to_dev(request->wiphy)->scan_req = NULL; | ||
51 | kfree(request); | 50 | kfree(request); |
52 | } | 51 | } |
53 | EXPORT_SYMBOL(cfg80211_scan_done); | 52 | EXPORT_SYMBOL(cfg80211_scan_done); |
@@ -119,7 +118,7 @@ static int cmp_ies(u8 num, u8 *ies1, size_t len1, u8 *ies2, size_t len2) | |||
119 | 118 | ||
120 | if (!ie1 && !ie2) | 119 | if (!ie1 && !ie2) |
121 | return 0; | 120 | return 0; |
122 | if (!ie1) | 121 | if (!ie1 || !ie2) |
123 | return -1; | 122 | return -1; |
124 | 123 | ||
125 | r = memcmp(ie1 + 2, ie2 + 2, min(ie1[1], ie2[1])); | 124 | r = memcmp(ie1 + 2, ie2 + 2, min(ie1[1], ie2[1])); |
@@ -172,6 +171,8 @@ static bool is_mesh(struct cfg80211_bss *a, | |||
172 | ie = find_ie(WLAN_EID_MESH_CONFIG, | 171 | ie = find_ie(WLAN_EID_MESH_CONFIG, |
173 | a->information_elements, | 172 | a->information_elements, |
174 | a->len_information_elements); | 173 | a->len_information_elements); |
174 | if (!ie) | ||
175 | return false; | ||
175 | if (ie[1] != IEEE80211_MESH_CONFIG_LEN) | 176 | if (ie[1] != IEEE80211_MESH_CONFIG_LEN) |
176 | return false; | 177 | return false; |
177 | 178 | ||