Commit da3e3fc7 authored by YAMAMOTO Mitsuharu's avatar YAMAMOTO Mitsuharu

Avoid compiler warnings on cairo build

* src/image.c (jpeg_load_body) [USE_CAIRO]: #ifdef out USE_SAFE_ALLOCA
and SAFE_FREE.
* src/xterm.c (x_composite_image) [USE_CAIRO]: #ifdef out unused function.
(x_draw_image_glyph_string) [USE_CAIRO]: #ifdef out unused variable pixmap.
parent 9800df69
Pipeline #1297 failed with stage
in 50 minutes and 11 seconds
......@@ -7043,7 +7043,9 @@ jpeg_load_body (struct frame *f, struct image *img,
colors generated, and mgr->cinfo.colormap is a two-dimensional array
of color indices in the range 0..mgr->cinfo.actual_number_of_colors.
No more than 255 colors will be generated. */
#ifndef USE_CAIRO
USE_SAFE_ALLOCA;
#endif
{
if (mgr->cinfo.out_color_components > 2)
ir = 0, ig = 1, ib = 2;
......@@ -7127,8 +7129,8 @@ jpeg_load_body (struct frame *f, struct image *img,
/* Put ximg into the image. */
image_put_x_image (f, img, ximg, 0);
#endif
SAFE_FREE ();
#endif
return 1;
}
......
......@@ -2989,6 +2989,7 @@ x_draw_glyph_string_box (struct glyph_string *s)
}
#ifndef USE_CAIRO
static void
x_composite_image (struct glyph_string *s, Pixmap dest,
int srcX, int srcY, int dstX, int dstY,
......@@ -3028,6 +3029,7 @@ x_composite_image (struct glyph_string *s, Pixmap dest,
srcX, srcY,
width, height, dstX, dstY);
}
#endif /* !USE_CAIRO */
/* Draw foreground of image glyph string S. */
......@@ -3335,7 +3337,9 @@ x_draw_image_glyph_string (struct glyph_string *s)
int box_line_hwidth = eabs (s->face->box_line_width);
int box_line_vwidth = max (s->face->box_line_width, 0);
int height;
#ifndef USE_CAIRO
Pixmap pixmap = None;
#endif
height = s->height;
if (s->slice.y == 0)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment