qcacld-3.0: Fix TDLS memory leak in SSR and driver unload

In SSR or driver unloading case, directly exit may cause obj
leak. Free the objects in those cases, regardless of
sme_close_session status

Change-Id: Iaf0500aca23917f84c37848cd3abade66b7d7456
CRs-Fixed: 2187579
This commit is contained in:
Kabilan Kannan
2018-02-15 17:43:21 -08:00
committed by snandini
parent 567e109c81
commit b867c313fe

View File

@@ -3680,7 +3680,7 @@ release_vdev:
* In SSR or driver unloading case, directly exit may cause objects
* leak, if sme_close_session failed. Free objects anyway.
*/
if (errno && !(cds_is_driver_recovering() || cds_is_driver_unloading()))
if (errno && !cds_is_driver_recovering() && !cds_is_driver_unloading())
return errno;
/* do vdev logical destroy via objmgr */