Initialize wpa_ie_len to 0 if WPA IE is not set on all paths
The new WPS code was not setting this in error case.
This commit is contained in:
parent
862e08a9a4
commit
243869858a
1 changed files with 2 additions and 1 deletions
|
@ -1027,7 +1027,8 @@ void wpa_supplicant_associate(struct wpa_supplicant *wpa_s,
|
|||
if (wps_ie && wpabuf_len(wps_ie) <= sizeof(wpa_ie)) {
|
||||
wpa_ie_len = wpabuf_len(wps_ie);
|
||||
os_memcpy(wpa_ie, wpabuf_head(wps_ie), wpa_ie_len);
|
||||
}
|
||||
} else
|
||||
wpa_ie_len = 0;
|
||||
wpabuf_free(wps_ie);
|
||||
wpa_supplicant_set_non_wpa_policy(wpa_s, ssid);
|
||||
#endif /* CONFIG_WPS */
|
||||
|
|
Loading…
Reference in a new issue