lkml.org 
[lkml]   [2006]   [Jun]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subjectstv680 boolean logic bug.
This looks closer to what I believe the original intent was.
(Also fixes line-len to meet CodingStyle)

Signed-off-by: Dave Jones <davej@redhat.com>

--- linux-2.6/drivers/media/video/stv680.c~ 2006-06-22 20:38:21.000000000 -0400
+++ linux-2.6/drivers/media/video/stv680.c 2006-06-22 20:39:02.000000000 -0400
@@ -974,7 +974,8 @@ static void bayer_unshuffle (struct usb_
frame->grabstate = FRAME_DONE;
stv680->framecount++;
stv680->readcount++;
- if (stv680->frame[(stv680->curframe + 1) & (STV680_NUMFRAMES - 1)].grabstate == FRAME_READY) {
+ if (stv680->frame[(stv680->curframe + 1) &&
+ (STV680_NUMFRAMES - 1)].grabstate == FRAME_READY) {
stv680->curframe = (stv680->curframe + 1) & (STV680_NUMFRAMES - 1);
}

--
http://www.codemonkey.org.uk
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-06-23 02:43    [W:0.034 / U:0.196 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site