ASoC: soc-jack: calling snd_soc_jack_report causes a null pointer access
A message that is not in the archive (sent off-list or not yet received): [email protected]
PATCH 1/1 ASoC: soc-jack: calling snd_soc_jack_report causes a null pointer access
Quoted 27 lines
From: mnlife <[email protected]>
When
snd_soc_card_jack_newis not called or the call fails, calling this function causes a null pointer accessSigned-off-by mnlife <[email protected]>--- sound/soc/soc-jack.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)sound/soc/soc-jack.c +1
-2@@ -44,7 +44,7 @@ void snd_soc_jack_report(struct snd_soc_jack *jack, int status, int mask)unsigned int sync =0 ;int enable; -if (!jack) +if (!jack || !jack->jack)return ;trace_snd_soc_jack_report (jack, mask, status); --2.17.1