mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-24 21:54:34 -04:00
qcacld-3.0: Release mutex properly when TDLS peer not found
Mutex is not released properly in the loop when the TDLS peer is not found in the function wlan_hdd_tdls_disable_ offchan_and_teardown_links(), that can cause crash. This change releases the mutex properly in the function wlan_hdd_tdls_disable_offchan_and_teardown_links() when TDLS peer is not found, and going for the next loop. Change-Id: Ia226c71e91e0e5995dd86557e0135508f32d8bef CRs-Fixed: 2058784
This commit is contained in:
parent
28b297c547
commit
e410b80979
1 changed files with 3 additions and 1 deletions
|
|
@ -271,8 +271,10 @@ void wlan_hdd_tdls_disable_offchan_and_teardown_links(hdd_context_t *hddctx)
|
|||
mutex_lock(&hddctx->tdls_lock);
|
||||
curr_peer = wlan_hdd_tdls_find_all_peer(hddctx,
|
||||
hddctx->tdlsConnInfo[staidx].peerMac.bytes);
|
||||
if (!curr_peer)
|
||||
if (!curr_peer) {
|
||||
mutex_unlock(&hddctx->tdls_lock);
|
||||
continue;
|
||||
}
|
||||
|
||||
hdd_notice("indicate TDLS teardown (staId %d)",
|
||||
curr_peer->staId);
|
||||
|
|
|
|||
Loading…
Reference in a new issue