Browse Source

qcacld-3.0: Fix null pointer check condition for local_ie

In function csr_remove_from_tmp_list, fix null pointer check condition
so that either local_ie is null or csr_remove_from_tmp_list failed. This
will ensure local_ie is valid before being dereferenced.

Change-Id: I91eda3ebe3d841f94f78b35d686e31b47ece8a79
CRs-Fixed: 1091486
Naveen Rawat 8 years ago
parent
commit
c8feebd21c
1 changed files with 1 additions and 1 deletions
  1. 1 1
      core/sme/src/csr/csr_api_scan.c

+ 1 - 1
core/sme/src/csr/csr_api_scan.c

@@ -2912,7 +2912,7 @@ csr_remove_from_tmp_list(tpAniSirGlobal mac_ctx,
 		local_ie = (tDot11fBeaconIEs *)(bss_dscp->Result.pvIes);
 		status = csr_get_parsed_bss_description_ies(mac_ctx,
 				&bss_dscp->Result.BssDescriptor, &local_ie);
-		if (!(local_ie || QDF_IS_STATUS_SUCCESS(status))) {
+		if (!local_ie || !QDF_IS_STATUS_SUCCESS(status)) {
 			sms_log(mac_ctx, LOGE, FL("Cannot pared IEs"));
 			csr_free_scan_result_entry(mac_ctx, bss_dscp);
 			continue;