From: Gerd Knorr <kraxel@bytesex.org>
To: Andrew Morton <akpm@osdl.org>
Cc: Kernel List <linux-kernel@vger.kernel.org>
Subject: [patch] v4l/bttv: add sanity check (bug #3309)
Date: Mon, 30 Aug 2004 14:52:34 +0200 [thread overview]
Message-ID: <20040830125233.GA1727@bytesex> (raw)
In-Reply-To: <20040830025443.3aad9fa4.akpm@osdl.org>
> Software Environment: gnomemeeting
> Problem Description: I have a miropctv (bttv card=1), kernel serie 2.4 have v4l
> only implementation. Kernel serie 2.6 have v4l2 only implementation (v4l
> broken). I had to go back to 2.4 to use gnomemeeting (v4l only). Everything is
> fine in 2.4.x. With 2.6, programs using v4l2 works ok (xawtv, ...); and programs
> using v4l crash:
> Aug 25 19:20:19 zain kernel: kernel BUG at drivers/media/video/bttv-driver.c:1900!
Missing sanity check, overlay is supported for packed pixel formats
only. Patch below. It's not API related btw, the bug can be triggered
using the v4l2 API as well.
Gerd
diff -u linux-2.6.9-rc1/drivers/media/video/bttv-driver.c linux/drivers/media/video/bttv-driver.c
--- linux-2.6.9-rc1/drivers/media/video/bttv-driver.c 2004-08-25 18:23:10.000000000 +0200
+++ linux/drivers/media/video/bttv-driver.c 2004-08-30 14:42:43.321218189 +0200
@@ -1861,6 +1861,8 @@
if (NULL == fh->ovfmt)
return -EINVAL;
+ if (!(fh->ovfmt->flags & FORMAT_FLAGS_PACKED))
+ return -EINVAL;
retval = verify_window(&bttv_tvnorms[btv->tvnorm],win,fixup);
if (0 != retval)
return retval;
parent reply other threads:[~2004-08-30 13:20 UTC|newest]
Thread overview: expand[flat|nested] mbox.gz Atom feed
[parent not found: <20040830025443.3aad9fa4.akpm@osdl.org>]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20040830125233.GA1727@bytesex \
--to=kraxel@bytesex.org \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox