android_kernel_xiaomi_sm8350/core/sap
gaurank kathpalia 16a721a680 qcacld-3.0: Fix memory leak issue of ch_list in sap_get_channel_list
In the api sap_get_channel_list, list is allocated memory to store the
channel list to be sent for scan request. This api is called by
sap_goto_channel_sel which initializes scan_request.ChannelInfo.ChannelList
to channel_list, without any prior NULL check of channel_list.
Also in scan callback wlansap_scan_callback, if the state machine structure
is in disconnected state , the host returns without freeing the memory
allocated to the channel list in sap_ctx .

Fix is to free the memory allocated to the channel list
and make the sap_ctx->channellist, sap_ctx->num_of_channel
as NULL and zero respectively in both the instances.

Change-Id: Ia54287d6e77e206c717bd3c205ebe57510ea801c
CRs-Fixed: 2159489
2017-12-20 19:27:21 -08:00
..
inc qcacld-3.0: (Part-2) Refactor open and close session logic in SAP module 2017-11-22 17:41:23 -08:00
src qcacld-3.0: Fix memory leak issue of ch_list in sap_get_channel_list 2017-12-20 19:27:21 -08:00