[gtk+] broadway: make sure color/delta run length do not overflow



commit ad39298f6d641a8dcaf5074dc9c3e71dad6a9ab5
Author: Pierre-Eric Pelloux-Prayer <pierre-eric lanedo com>
Date:   Wed Mar 12 17:02:58 2014 +0100

    broadway: make sure color/delta run length do not overflow
    
    Fixes bug 723045.

 gdk/broadway/broadway-buffer.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/gdk/broadway/broadway-buffer.c b/gdk/broadway/broadway-buffer.c
index f1ce426..a03e12c 100644
--- a/gdk/broadway/broadway-buffer.c
+++ b/gdk/broadway/broadway-buffer.c
@@ -228,7 +228,9 @@ encode_pixel (struct encoder *encoder, guint32 color, guint32 prev_color)
       (encoder->delta != delta &&
        encoder->delta_run > encoder->color_run) ||
 
-      (encoder->delta != delta && encoder->color != color))
+      (encoder->delta != delta && encoder->color != color) ||
+
+      (encoder->delta_run == 0xFFFFF || encoder->color_run == 0xFFFFF))
     {
       encode_run (encoder);
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]