qcacld-3.0: Fix incorrect NULL pointer check for SAP

Propagate from qcacld-2.0 to qcacld-3.0

Currently there are some places where array name is compared to NULL
in SAP, add fix to correct it.

CRs-Fixed: 1063255
Change-Id: I736ac42dd08cd6d3375b7693e914e825dae6c702
diff --git a/core/sap/src/sap_ch_select.c b/core/sap/src/sap_ch_select.c
index 0535060..a254d83 100644
--- a/core/sap/src/sap_ch_select.c
+++ b/core/sap/src/sap_ch_select.c
@@ -1231,22 +1231,24 @@
 		vhtSupport = 0;
 		centerFreq = 0;
 
-		if (pScanResult->BssDescriptor.ieFields != NULL) {
-			ieLen = GET_IE_LEN_IN_BSS(
-					pScanResult->BssDescriptor.length);
-			qdf_mem_set((uint8_t *) pBeaconStruct,
-				    sizeof(tSirProbeRespBeacon), 0);
 
-			if ((sir_parse_beacon_ie
-				     (pMac, pBeaconStruct, (uint8_t *)
-				      (pScanResult->BssDescriptor.ieFields),
-				      ieLen)) == eSIR_SUCCESS) {
-				sap_upd_chan_spec_params(pBeaconStruct,
-					&channelWidth, &secondaryChannelOffset,
-					&vhtSupport, &centerFreq,
-					&centerFreq_2);
-			}
-		}
+		ieLen = GET_IE_LEN_IN_BSS(
+				pScanResult->BssDescriptor.length);
+		qdf_mem_set((uint8_t *) pBeaconStruct,
+				   sizeof(tSirProbeRespBeacon), 0);
+
+
+		if ((sir_parse_beacon_ie
+		     (pMac, pBeaconStruct, (uint8_t *)
+		      (pScanResult->BssDescriptor.ieFields),
+		      ieLen)) == eSIR_SUCCESS)
+			sap_upd_chan_spec_params(
+				pBeaconStruct,
+				&channelWidth,
+				&secondaryChannelOffset,
+				&vhtSupport, &centerFreq,
+				&centerFreq_2);
+
 		/* Processing for each tCsrScanResultInfo in the tCsrScanResult DLink list */
 		for (chn_num = 0; chn_num < pSpectInfoParams->numSpectChans;
 		     chn_num++) {