[media] usbtv: fix leak at failure path in usbtv_probe()
Error handling code in usbtv_probe() misses usb_put_dev(). Found by Linux Driver Verification project (linuxtesting.org). Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru> Acked-by: Lubomir Rintel <lkundrak@v3.sk> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
This commit is contained in:
parent
f8d36b8960
commit
ebdae6507b
@ -91,6 +91,8 @@ static int usbtv_probe(struct usb_interface *intf,
|
||||
return 0;
|
||||
|
||||
usbtv_video_fail:
|
||||
usb_set_intfdata(intf, NULL);
|
||||
usb_put_dev(usbtv->udev);
|
||||
kfree(usbtv);
|
||||
|
||||
return ret;
|
||||
|
Loading…
x
Reference in New Issue
Block a user