Skip to contentSkip to conversation

drivers/net/wireless/quantenna/qtnfmac/pcie/pearl_pcie.c:596 qtnf_pcie_skb_send() warn: variable dereferenced before check 'skb' (see line 560)

PATCH Dan Carpenter 1 participant 1 message Nov 21, 2019 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw
Quoted 5 lines · Igor Mitsyanko

Thanks Dan!

@Sergey I think we do not need !skb check at all in this function, agree? I assume if we remove "if (ret && skb)" it will make smatch happy?

Yes. Smatch only cares about consistent checking. Or it will accept inconsistent NULL checks so long as it is convinced that the pointer can't be NULL.

regards,
dan carpenter