Explorar el Código

qcacmn: Replace correct pointer to check NULL

To fix coding error which find by static analysis.

Change-Id: I46017721945aef60def49a8e90ffb2da1dfaf5e6
CRs-Fixed: 3642679
Will Huang hace 1 año
padre
commit
6dc43655d9
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      os_if/linux/afc/src/wlan_cfg80211_afc.c

+ 1 - 1
os_if/linux/afc/src/wlan_cfg80211_afc.c

@@ -864,7 +864,7 @@ static struct afc_resp_extracted *extract_afc_resp(struct nlattr **attr)
 	if (attr[QCA_WLAN_VENDOR_ATTR_AFC_RESP_DATA]) {
 		nl = attr[QCA_WLAN_VENDOR_ATTR_AFC_RESP_DATA];
 		afc_rsp->json_data = qdf_mem_malloc(nla_len(nl));
-		if (!afc_rsp)
+		if (!afc_rsp->json_data)
 			goto fail;
 
 		afc_rsp->json_len = nla_len(nl);