[byzanz] Fix compiler warnings



commit c59008844754279fbb2c2ac501c61538f80d1cc0
Author: Christopher Aillon <caillon redhat com>
Date:   Wed Feb 16 19:03:21 2011 -0800

    Fix compiler warnings
    
    gifenc.c: In function 'gifenc_dither_rgb':
    gifenc.c:479:15: error: variable 'i' set but not used [-Werror=unused-but-set-variable]
    gifenc.c: In function 'gifenc_dither_rgb_with_full_image':
    gifenc.c:536:13: error: variable 'i' set but not used [-Werror=unused-but-set-variable]

 gifenc/gifenc.c |    6 ++----
 1 files changed, 2 insertions(+), 4 deletions(-)
---
diff --git a/gifenc/gifenc.c b/gifenc/gifenc.c
index af80014..07c20b5 100644
--- a/gifenc/gifenc.c
+++ b/gifenc/gifenc.c
@@ -476,7 +476,7 @@ gifenc_dither_rgb (guint8* target, guint target_rowstride,
     const GifencPalette *palette, const guint8 *data, guint width, guint height, 
     guint rowstride)
 {
-  guint x, y, i, c;
+  guint x, y, c;
   gint *this_error, *next_error;
   guint8 this[3];
   gint err[3] = { 0, 0, 0 };
@@ -486,7 +486,6 @@ gifenc_dither_rgb (guint8* target, guint target_rowstride,
 
   this_error = g_new0 (gint, (width + 2) * 3);
   next_error = g_new (gint, (width + 2) * 3);
-  i = 0;
   for (y = 0; y < height; y++) {
     const guint32 *row = (const guint32 *) data;
     gint *cur_error = this_error + 3;
@@ -533,7 +532,7 @@ gifenc_dither_rgb_with_full_image (guint8 *target, guint target_rowstride,
     const GifencPalette *palette, const guint8 *data, guint width, guint height, 
     guint rowstride, GdkRectangle *rect_out)
 {
-  int x, y, i, c;
+  int x, y, c;
   gint *this_error, *next_error;
   guint8 this[3], alpha;
   gint err[3] = { 0, 0, 0 };
@@ -546,7 +545,6 @@ gifenc_dither_rgb_with_full_image (guint8 *target, guint target_rowstride,
 
   this_error = g_new0 (gint, (width + 2) * 3);
   next_error = g_new (gint, (width + 2) * 3);
-  i = 0;
   for (y = 0; y < (int) height; y++) {
     const guint32 *row = (const guint32 *) data;
     gint *cur_error = this_error + 3;



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