mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-11-09 20:31:13 -05:00
qcacld-3.0: Fix possible null pointer dereference
Fix a possible null pointer dereference in wlan_hdd_cfg80211_ll_stats_get and _wlan_hdd_cfg80211_get_station if global qdf device context becomes null. Change-Id: I02362ae2c60769a562acc42805bd8c4ccac0e887 CRs-fixed: 2536319
This commit is contained in:
parent
32ee7f4d89
commit
1f380148ad
1 changed files with 6 additions and 0 deletions
|
|
@ -1552,6 +1552,9 @@ int wlan_hdd_cfg80211_ll_stats_get(struct wiphy *wiphy,
|
|||
int errno;
|
||||
qdf_device_t qdf_ctx = cds_get_context(QDF_MODULE_ID_QDF_DEVICE);
|
||||
|
||||
if (!qdf_ctx)
|
||||
return -EINVAL;
|
||||
|
||||
errno = osif_vdev_sync_op_start(wdev->netdev, &vdev_sync);
|
||||
if (errno)
|
||||
return errno;
|
||||
|
|
@ -4688,6 +4691,9 @@ static int _wlan_hdd_cfg80211_get_station(struct wiphy *wiphy,
|
|||
if (errno)
|
||||
return errno;
|
||||
|
||||
if (!qdf_ctx)
|
||||
return -EINVAL;
|
||||
|
||||
errno = pld_qmi_send_get(qdf_ctx->dev);
|
||||
if (errno)
|
||||
return errno;
|
||||
|
|
|
|||
Loading…
Reference in a new issue