mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-15 01:01:56 -04:00
qcacld-3.0: Add check for vdev_id in wma_unified_bcntx_status_event_handler
Currently resp_event->vdev_id, recevied from the FW, is directly used to refer to wma->interfaces without validating if the vdev_id is valid. Add sanity check to make sure vdev_id is less than max_bssid before using it. Change-Id: I734ff795a3936719b08493f868384dbde72a80df CRs-Fixed: 2119394
This commit is contained in:
parent
a35ca6dbf5
commit
07db59ed46
1 changed files with 6 additions and 0 deletions
|
|
@ -517,6 +517,12 @@ int wma_unified_bcntx_status_event_handler(void *handle,
|
|||
|
||||
WMA_LOGD("%s", __func__);
|
||||
|
||||
if (resp_event->vdev_id >= wma->max_bssid) {
|
||||
WMA_LOGE("%s: received invalid vdev_id %d",
|
||||
__func__, resp_event->vdev_id);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
/* Check for valid handle to ensure session is not
|
||||
* deleted in any race
|
||||
*/
|
||||
|
|
|
|||
Loading…
Reference in a new issue