mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-14 16:46:15 -04:00
qcacld-3.0: Add NULL IE check
Beacons with NULL IE's are triggering crash in framework. Add condition check in WMA to drop beacons with NULL IE. Change-Id: Ie28cd513713668334a77a2e8f5f345d79f68fcb5 CRs-Fixed: 2047525
This commit is contained in:
parent
4a58f7f2a5
commit
2a206c568a
1 changed files with 13 additions and 0 deletions
|
|
@ -3567,6 +3567,19 @@ int wma_form_rx_packet(qdf_nbuf_t buf,
|
|||
rx_pkt->pkt_meta.sessionId =
|
||||
(vdev_id == WMA_INVALID_VDEV_ID ? 0 : vdev_id);
|
||||
|
||||
if (mgt_type == IEEE80211_FC0_TYPE_MGT &&
|
||||
(mgt_subtype == IEEE80211_FC0_SUBTYPE_BEACON ||
|
||||
mgt_subtype == IEEE80211_FC0_SUBTYPE_PROBE_RESP)) {
|
||||
if (mgmt_rx_params->buf_len <=
|
||||
(sizeof(struct ieee80211_frame) +
|
||||
offsetof(struct wlan_bcn_frame, ie))) {
|
||||
WMA_LOGD("Dropping frame from "MAC_ADDRESS_STR,
|
||||
MAC_ADDR_ARRAY(wh->i_addr3));
|
||||
cds_pkt_return_packet(rx_pkt);
|
||||
return -EINVAL;
|
||||
}
|
||||
}
|
||||
|
||||
if (wma_is_pkt_drop_candidate(wma_handle, wh->i_addr2, wh->i_addr3,
|
||||
mgt_subtype)) {
|
||||
cds_pkt_return_packet(rx_pkt);
|
||||
|
|
|
|||
Loading…
Reference in a new issue