[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200710142003.20323.hverkuil@xs4all.nl>
Date: Sun, 14 Oct 2007 20:03:20 +0200
From: Hans Verkuil <hverkuil@...all.nl>
To: Adrian Bunk <bunk@...nel.org>
Cc: Mauro Carvalho Chehab <mchehab@...radead.org>,
v4l-dvb-maintainer@...uxtv.org, linux-kernel@...r.kernel.org
Subject: Re: [2.6 patch] ivtv: fix NULL dereference
On Sunday 14 October 2007 19:51:37 Adrian Bunk wrote:
> We shouldn't dereference "itv" when we know it's NULL...
>
> Spotted by the Coverity checker.
>
> Signed-off-by: Adrian Bunk <bunk@...nel.org>
>
> ---
> --- linux-2.6/drivers/media/video/ivtv/ivtv-fileops.c.old 2007-10-14
> 19:17:12.000000000 +0200 +++
> linux-2.6/drivers/media/video/ivtv/ivtv-fileops.c 2007-10-14
> 19:18:05.000000000 +0200 @@ -947,7 +947,7 @@ int
> ivtv_v4l2_open(struct inode *inode,
> 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;
> }
Signed-off-by: Hans Verkuil <hverkuil@...all.nl>
Luckily this is something that 'shoudn't happen' :-)
Oddly enough it is correct in my standalone driver.
Mauro, can you merge this with 2.6.24 as well? Or shall I add it to my
ivtv tree with my other outstanding fixes?
Regards,
Hans
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists