Browse Source

V4L/DVB (6328): ivtv: fix NULL dereference

We shouldn't dereference "itv" when we know it's NULL...

Spotted by the Coverity checker.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Reviewed-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Adrian Bunk 18 years ago
parent
commit
7e7f05ca15
1 changed files with 1 additions and 1 deletions
  1. 1 1
      drivers/media/video/ivtv/ivtv-fileops.c

+ 1 - 1
drivers/media/video/ivtv/ivtv-fileops.c

@@ -947,7 +947,7 @@ int ivtv_v4l2_open(struct inode *inode, struct file *filp)
 	if (itv == NULL) {
 		/* Couldn't find a device registered
 		   on that minor, shouldn't happen! */
-		IVTV_WARN("No ivtv device found on minor %d\n", minor);
+		printk(KERN_WARNING "No ivtv device found on minor %d\n", minor);
 		return -ENXIO;
 	}