From 1bcc27985fe76a674ea5b8a24b1bad544390b301 Mon Sep 17 00:00:00 2001 From: Andrea Canciani Date: Fri, 2 Sep 2011 12:51:10 +0200 Subject: perf: Fix win32 build Microsoft C Compiler complains about: hash-table.c(44) : error C2466: cannot allocate an array of constant size 0 Adding an unused element makes it happy. --- perf/micro/hash-table.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'perf') diff --git a/perf/micro/hash-table.c b/perf/micro/hash-table.c index dc8975d4..a0266381 100644 --- a/perf/micro/hash-table.c +++ b/perf/micro/hash-table.c @@ -41,7 +41,12 @@ static cairo_time_t do_hash_table (cairo_t *cr, int width, int height, int loops) { - cairo_scaled_font_t *active_fonts[ACTIVE_FONTS]; + /* + * Microsoft C Compiler complains that: + * error C2466: cannot allocate an array of constant size 0 + * so we add an unused element to make it happy + */ + cairo_scaled_font_t *active_fonts[ACTIVE_FONTS + 1]; cairo_matrix_t m; int i; -- cgit v1.2.3