提交 feabb67e 编写于 作者: D Dan Carpenter 提交者: Takashi Iwai

ALSA: lola: NULL dereference on probe failure

"card" is NULL if snd_card_new() fails.
Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: NTakashi Iwai <tiwai@suse.de>
上级 9faa73f0
......@@ -719,7 +719,7 @@ static int lola_probe(struct pci_dev *pci,
err = snd_card_new(&pci->dev, index[dev], id[dev], THIS_MODULE,
0, &card);
if (err < 0) {
dev_err(card->dev, "Error creating card!\n");
dev_err(&pci->dev, "Error creating card!\n");
return err;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册