From f88f8295d8a9229fc8b647baf4f15959384d7bb7 Mon Sep 17 00:00:00 2001 From: Adrian Bunk Date: Fri, 10 Mar 2006 23:25:06 +0100 Subject: [PATCH] [PATCH] USB: vicam.c: fix a NULL pointer dereference This patch fixes a NULL pointer dereference spotted by the Coverity checker. Signed-off-by: Adrian Bunk Signed-off-by: Greg Kroah-Hartman --- drivers/usb/media/vicam.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/media/vicam.c b/drivers/usb/media/vicam.c index 8cfc47b831fb..1d06e53ec7c5 100644 --- a/drivers/usb/media/vicam.c +++ b/drivers/usb/media/vicam.c @@ -764,6 +764,7 @@ vicam_open(struct inode *inode, struct file *file) if (!cam) { printk(KERN_ERR "vicam video_device improperly initialized"); + return -EINVAL; } /* the videodev_lock held above us protects us from -- 2.30.2