All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] TM6000: Fix code which cause memory corruption
@ 2010-04-07 23:57 Bee Hock Goh
  0 siblings, 0 replies; only message in thread
From: Bee Hock Goh @ 2010-04-07 23:57 UTC (permalink / raw)
  To: Linux Media

code was doing malloc when buf is null causing memory corruption. The
analog part is still pretty much broken but at least fixing this will
stop it from crashing the machine when streamon.

Signed-off-by: Bee Hock Goh <beehock@gmail.com>
diff -r 7c0b887911cf linux/drivers/staging/tm6000/tm6000-video.c
--- a/linux/drivers/staging/tm6000/tm6000-video.c       Mon Apr 05
22:56:43 2010 -0400
+++ b/linux/drivers/staging/tm6000/tm6000-video.c       Thu Apr 08
07:45:05 2010 +0800
@@ -502,7 +502,7 @@
        unsigned long copied;

        get_next_buf(dma_q, &buf);
-       if (!buf)
+       if (buf)
                outp = videobuf_to_vmalloc(&buf->vb);

        if (!outp)

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2010-04-07 23:57 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-04-07 23:57 [PATCH] TM6000: Fix code which cause memory corruption Bee Hock Goh

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.