struct mlme_priv *pmlmepriv = &adapter->mlmepriv;
struct survey_event *survey = (struct survey_event *)pbuf;
- pnetwork = &survey->bss;
+ pnetwork = survey->bss;
RT_TRACE(_module_rtl871x_mlme_c_,_drv_info_,
("rtw_survey_event_cb23a, ssid=%s\n", pnetwork->Ssid.ssid));
spin_unlock_bh(&pmlmepriv->lock);
+ kfree(survey->bss);
+ survey->bss = NULL;
+
return;
}
pc2h_evt_hdr->seq = atomic_inc_return(&pmlmeext->event_seq);
psurvey_evt = (struct survey_event*)(pevtcmd + sizeof(struct C2HEvent_Header));
+ psurvey_evt->bss = kzalloc(sizeof(struct wlan_bssid_ex), GFP_ATOMIC);
+ if (!psurvey_evt->bss) {
+ kfree(pcmd_obj);
+ kfree(pevtcmd);
+ }
- if (collect_bss_info23a(padapter, precv_frame, &psurvey_evt->bss) == _FAIL) {
+ if (collect_bss_info23a(padapter, precv_frame, psurvey_evt->bss) == _FAIL) {
kfree(pcmd_obj);
kfree(pevtcmd);
return;
}
- process_80211d(padapter, &psurvey_evt->bss);
+ process_80211d(padapter, psurvey_evt->bss);
rtw_enqueue_cmd23a(pcmdpriv, pcmd_obj);