nl80211: Provide frequency in EVENT_ASSOC when IBSS is joined

Provides operating frequency in EVENT_ASSOC when IBSS is joined so that
wpa_s->assoc_freq can be updated when any IBSS network is joined.

Signed-off-by: Saurav Babu <saurav.babu@samsung.com>
This commit is contained in:
Saurav Babu 2016-07-01 12:06:17 +00:00 committed by Jouni Malinen
parent a8fd58aa42
commit f0e84057fb

View file

@ -916,6 +916,7 @@ static void mlme_event_join_ibss(struct wpa_driver_nl80211_data *drv,
struct nlattr *tb[])
{
unsigned int freq;
union wpa_event_data event;
if (tb[NL80211_ATTR_MAC] == NULL) {
wpa_printf(MSG_DEBUG, "nl80211: No address in IBSS joined "
@ -935,7 +936,10 @@ static void mlme_event_join_ibss(struct wpa_driver_nl80211_data *drv,
drv->first_bss->freq = freq;
}
wpa_supplicant_event(drv->ctx, EVENT_ASSOC, NULL);
os_memset(&event, 0, sizeof(event));
event.assoc_info.freq = freq;
wpa_supplicant_event(drv->ctx, EVENT_ASSOC, &event);
}