mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-10 22:40:54 -04:00
qcacld-3.0: Add Null check for soc before accessing
Check if the soc pointer is not NULL, before we try to derefernce this pointer. Change-Id: Ife499e7617365278c4ac8fd41e2ce32d4e19fae9 CRs-Fixed: 2702127
This commit is contained in:
parent
fb96116daa
commit
efb077864e
1 changed files with 3 additions and 0 deletions
|
|
@ -2044,6 +2044,9 @@ QDF_STATUS hdd_rx_flush_packet_cbk(void *adapter_context, uint8_t vdev_id)
|
|||
struct hdd_context *hdd_ctx;
|
||||
ol_txrx_soc_handle soc = cds_get_context(QDF_MODULE_ID_SOC);
|
||||
|
||||
if (qdf_unlikely(!soc))
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
|
||||
hdd_ctx = cds_get_context(QDF_MODULE_ID_HDD);
|
||||
if (unlikely(!hdd_ctx)) {
|
||||
QDF_TRACE(QDF_MODULE_ID_HDD_DATA, QDF_TRACE_LEVEL_ERROR,
|
||||
|
|
|
|||
Loading…
Reference in a new issue