提交 407df293 编写于 作者: R Roel Kluin 提交者: Mauro Carvalho Chehab

V4L/DVB: dvb: return -ENOMEM if kzalloc failed in dvb_usb_device_init()

If in a cold state and the download succeeded ret is zero, but we
should return -ENOMEM.
Signed-off-by: NRoel Kluin <roel.kluin@gmail.com>
Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
上级 ca39d84d
......@@ -243,7 +243,7 @@ int dvb_usb_device_init(struct usb_interface *intf,
d = kzalloc(sizeof(struct dvb_usb_device),GFP_KERNEL);
if (d == NULL) {
err("no memory for 'struct dvb_usb_device'");
return ret;
return -ENOMEM;
}
d->udev = udev;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册