From 72028ce64069d44e60853327259e49f4f1d6f840 Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Wed, 2 Jan 2019 13:29:49 -0800 Subject: [PATCH] table: Avoid initializer warnings with GCC 4.9. --- src/output/cairo.c | 2 +- src/output/table.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/output/cairo.c b/src/output/cairo.c index b0915dc583..56919b8d77 100644 --- a/src/output/cairo.c +++ b/src/output/cairo.c @@ -1483,7 +1483,7 @@ xr_layout_cell_text (struct xr_driver *xr, const struct table_cell *cell, dump_line (xr, -xr->left_margin, best, xr->width + xr->right_margin, best, RENDER_LINE_SINGLE, - &CELL_COLOR (0, 255, 0)); + &(struct cell_color) CELL_COLOR (0, 255, 0)); } } diff --git a/src/output/table.h b/src/output/table.h index d162a28b4a..40cae3a22c 100644 --- a/src/output/table.h +++ b/src/output/table.h @@ -65,7 +65,7 @@ struct cell_color uint8_t alpha, r, g, b; }; -#define CELL_COLOR(r, g, b) (struct cell_color) { 255, r, g, b } +#define CELL_COLOR(r, g, b) { 255, r, g, b } #define CELL_COLOR_BLACK CELL_COLOR (0, 0, 0) #define CELL_COLOR_WHITE CELL_COLOR (255, 255, 255) -- 2.30.2