This is an automatic generated email to let you know that the following patch 
were queued at the 
http://git.linuxtv.org/cgit.cgi/tvtime.git tree:

Subject: Do not call videoinput_buffer_invalid with a negative index
Author:  Hans de Goede <[email protected]>
Date:    Sat Feb 13 16:47:36 2016 -0200

Signed-off-by: Hans de Goede <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>

 src/tvtime.c | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

---

http://git.linuxtv.org/cgit.cgi/tvtime.git/commit/?id=a426bf41b8af2b731ba7c51477cd2c91aedc38be
diff --git a/src/tvtime.c b/src/tvtime.c
index 86579814e5da..cddf9734e2d4 100644
--- a/src/tvtime.c
+++ b/src/tvtime.c
@@ -2086,17 +2086,20 @@ int tvtime_main( rtctimer_t *rtctimer, int read_stdin, 
int realtime,
                 } else {
                     /* Make sure our buffers are valid. */
                     if( fieldsavailable == 2 ) {
-                        if( videoinput_buffer_invalid( vidin, lastframeid ) ) {
+                       if( lastframeid == -1 ||
+                               videoinput_buffer_invalid( vidin, lastframeid ) 
) {
                             lastframe = curframe;
                             lastframeid = -1;
                         }
                     } else if( fieldsavailable == 4 ) {
-                        if( videoinput_buffer_invalid( vidin,
+                       if( secondlastframeid == -1 ||
+                               videoinput_buffer_invalid( vidin,
                                                        secondlastframeid ) ) {
                             secondlastframe = curframe;
                             secondlastframeid = -1;
                         }
-                        if( videoinput_buffer_invalid( vidin, lastframeid ) ) {
+                       if( lastframeid == -1 ||
+                               videoinput_buffer_invalid( vidin, lastframeid ) 
) {
                             lastframe = curframe;
                             lastframeid = -1;
                         }

_______________________________________________
linuxtv-commits mailing list
[email protected]
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linuxtv-commits

Reply via email to