diff options
author | Julia Lawall <julia@diku.dk> | 2011-08-12 13:40:08 +0200 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-09-03 23:43:58 +0200 |
commit | 0163b924c5c54f9737357f622fd923a9d80556bd (patch) | |
tree | 4a48704d19262a062671c2dec211835d9f71ed5d /drivers/media/video/zr364xx.c | |
parent | [media] MAINTAINERS: add entries for s5p-mfc and s5p-tv drivers (diff) | |
download | linux-0163b924c5c54f9737357f622fd923a9d80556bd.tar.xz linux-0163b924c5c54f9737357f622fd923a9d80556bd.zip |
[media] drivers/media/video/zr364xx.c: add missing cleanup code
It seems just as necessary to free cam->vdev and cam in this error case as
in the next one.
Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/zr364xx.c')
-rw-r--r-- | drivers/media/video/zr364xx.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/media/video/zr364xx.c b/drivers/media/video/zr364xx.c index c492846c1c5a..e78cf94f491e 100644 --- a/drivers/media/video/zr364xx.c +++ b/drivers/media/video/zr364xx.c @@ -1638,6 +1638,9 @@ static int zr364xx_probe(struct usb_interface *intf, if (!cam->read_endpoint) { dev_err(&intf->dev, "Could not find bulk-in endpoint\n"); + video_device_release(cam->vdev); + kfree(cam); + cam = NULL; return -ENOMEM; } |