Pārlūkot izejas kodu

qcacld-3.0: Remove dereferencing freed pointer in channel stat request

In api mlme_connected_chan_stats_request(), dereferencing
of freed pointer is observed by static analysis tool.

Remove dereferencing of the freed pointer in the api
mlme_connected_chan_stats_request().

Change-Id: Ic09b68395a9c3c67aab4a704a915b0d92a00e16d
CRs-Fixed: 3530020
Vijay Raj 1 gadu atpakaļ
vecāks
revīzija
03827cfd24
1 mainītis faili ar 2 papildinājumiem un 2 dzēšanām
  1. 2 2
      components/mlme/core/src/wlan_mlme_main.c

+ 2 - 2
components/mlme/core/src/wlan_mlme_main.c

@@ -586,7 +586,7 @@ QDF_STATUS mlme_connected_chan_stats_request(struct wlan_objmgr_psoc *psoc,
 
 	req->scan_req.scan_id = wlan_scan_get_scan_id(psoc);
 	req->scan_req.scan_req_id = mlme_obj->scan_requester_id;
-	req->scan_req.vdev_id = wlan_vdev_get_id(vdev);
+	req->scan_req.vdev_id = vdev_id;
 
 	req->scan_req.scan_type = SCAN_TYPE_DEFAULT;
 
@@ -614,7 +614,7 @@ QDF_STATUS mlme_connected_chan_stats_request(struct wlan_objmgr_psoc *psoc,
 	status = wlan_scan_start(req);
 	if (QDF_IS_STATUS_ERROR(status)) {
 		mlme_debug("vdev %d :Failed to send scan req, status %d",
-			   req->scan_req.vdev_id, status);
+			   vdev_id, status);
 		goto release;
 	}