suppress -Wunused-variable

master
Takeshi Abe 2013-04-11 19:05:04 +09:00
parent c5fcf8446b
commit aeb7fed08e
3 changed files with 9 additions and 3 deletions

View File

@ -2637,7 +2637,7 @@ BGD_DECLARE(void) gdImageCopyResampled (gdImagePtr dst,
double sx, sy;
double spixels = 0;
double red = 0.0, green = 0.0, blue = 0.0, alpha = 0.0;
double alpha_factor, alpha_sum = 0.0, contrib_sum = 0.0;
double alpha_sum = 0.0, contrib_sum = 0.0;
sx1 = ((double) x - (double) dstX) * (double) srcW / dstW;
sx2 = ((double) (x + 1) - (double) dstX) * (double) srcW / dstW;
@ -3381,7 +3381,6 @@ static void gdImageAALine (gdImagePtr im, int x1, int y1, int x2, int y2, int co
BGD_DECLARE(int) gdImagePaletteToTrueColor(gdImagePtr src)
{
unsigned int y;
unsigned char alloc_y = 0, alloc_aa = 0;
unsigned int yy;
if (src == NULL) {

View File

@ -39,11 +39,14 @@ BGD_DECLARE(gdImagePtr) gdImageCreateFromPngSource (gdSourcePtr inSource)
#else /* no HAVE_LIBPNG */
BGD_DECLARE(void) gdImagePngToSink (gdImagePtr im, gdSinkPtr outSink)
{
(void)im;
(void)outSink;
fprintf (stderr, "PNG support is not available\n");
}
BGD_DECLARE(gdImagePtr) gdImageCreateFromPngSource (gdSourcePtr inSource)
{
(void)inSource;
fprintf (stderr, "PNG support is not available\n");
return NULL;
}

View File

@ -36,12 +36,15 @@
/* number of antialised colors for indexed bitmaps */
#define GD_NUMCOLORS 8
#ifdef HAVE_LIBFONTCONFIG
static int fontConfigFlag = 0;
static char *font_path(char **fontpath, char *name_list);
/* translate a fontconfig fontpattern into a fontpath.
return NULL if OK, else return error string */
static char *font_pattern(char **fontpath, char *fontpattern);
#endif
static char *font_path(char **fontpath, char *name_list);
/* 2.0.30: move these up here so we can build correctly without freetype
but with fontconfig */
@ -1587,6 +1590,7 @@ BGD_DECLARE(int) gdFTUseFontConfig(int flag)
fontConfigFlag = flag;
return 1;
#else
(void)flag;
return 0;
#endif /* HAVE_LIBFONTCONFIG */
}