Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c17a49bd authored by Wu Gao's avatar Wu Gao Committed by Madan Koyyalamudi
Browse files

qcacmn: Check function pointer to avoid NULL point dereference

It calls spectral_process_phyerr of spectral operations without any
check. Which cause null point dereference potentially. So, check this
pointer before calling.

Change-Id: Iae246f847dd41e62b628223652a9527a65b43799
CRs-Fixed: 3055246
parent de365535
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -1546,6 +1546,10 @@ void target_if_spectral_process_phyerr(
	}

	p_sops = GET_TARGET_IF_SPECTRAL_OPS(spectral);
	if (!p_sops->spectral_process_phyerr) {
		spectral_err("null spectral_process_phyerr");
		return;
	}
	p_sops->spectral_process_phyerr(spectral, data, datalen,
					p_rfqual, p_chaninfo,
					tsf64, acs_stats);