ALSA: hda: fix possible NULL dereference
After a for-loop was replaced by list_for_each_entry, see Commit bbbc7e85 ("ALSA: hda - Allocate hda_pcm objects dynamically"), Commit 751e2216 ("ALSA: hda: fix possible null dereference"), a possible NULL pointer dereference has been introduced; this patch adds the NULL check on pcm->pcm, while leaving a potentially superfluous check on pcm itself untouched. Signed-off-by: NMarkus Osterhoff <linux-kernel@k-raum.org> Cc: <stable@vger.kernel.org> #v4.1+ Signed-off-by: NTakashi Iwai <tiwai@suse.de>
Showing
想要评论请 注册 或 登录