From 5b93254d0f71bd2b0fd6c94c847c77ef207c7d27 Mon Sep 17 00:00:00 2001 From: Andreas Tscharner Date: Tue, 8 Sep 2009 23:05:35 +0200 Subject: [PATCH] Fix compilation failure This fixes a compilation failure with gcc-4.3.4, where it complains nxpm.c: In function RGetImageFromXPMData: nxpm.c:99: error: expected expression before ] token ... --- wrlib/nxpm.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/wrlib/nxpm.c b/wrlib/nxpm.c index f9a8f06f..cd1da02e 100644 --- a/wrlib/nxpm.c +++ b/wrlib/nxpm.c @@ -96,7 +96,7 @@ RImage *RGetImageFromXPMData(RContext * context, char **data) if (!color_table[0] || !color_table[1] || !color_table[2] || !color_table[3] || !symbol_table || !bsize) { RErrorCode = RERR_NOMEMORY; - free_color_symbol_table(color_table[], symbol_table); + free_color_symbol_table(color_table, symbol_table); return NULL; } @@ -145,7 +145,7 @@ RImage *RGetImageFromXPMData(RContext * context, char **data) image = RCreateImage(w, h, transp); if (!image) { - free_color_symbol_table(color_table[], symbol_table); + free_color_symbol_table(color_table, symbol_table); return NULL; } @@ -215,12 +215,12 @@ RImage *RGetImageFromXPMData(RContext * context, char **data) line++; } - free_color_symbol_table(color_table[], symbol_table); + free_color_symbol_table(color_table, symbol_table); return image; bad_format: RErrorCode = RERR_BADIMAGEFILE; - free_color_symbol_table(color_table[], symbol_table); + free_color_symbol_table(color_table, symbol_table); if (image) RReleaseImage(image); return NULL; @@ -281,7 +281,7 @@ RImage *RLoadXPM(RContext * context, char *file, int index) !color_table[3] || !symbol_table || !bsize || !buffer) { RErrorCode = RERR_NOMEMORY; fclose(f); - free_color_symbol_table(color_table[], symbol_table); + free_color_symbol_table(color_table, symbol_table); if (buffer) free(buffer); return NULL; @@ -338,7 +338,7 @@ RImage *RLoadXPM(RContext * context, char *file, int index) image = RCreateImage(w, h, transp); if (!image) { fclose(f); - free_color_symbol_table(color_table[], symbol_table); + free_color_symbol_table(color_table, symbol_table); if (buffer) free(buffer); return NULL; @@ -417,7 +417,7 @@ RImage *RLoadXPM(RContext * context, char *file, int index) } fclose(f); - free_color_symbol_table(color_table[], symbol_table); + free_color_symbol_table(color_table, symbol_table); if (buffer) free(buffer); return image; @@ -425,7 +425,7 @@ RImage *RLoadXPM(RContext * context, char *file, int index) bad_format: RErrorCode = RERR_BADIMAGEFILE; fclose(f); - free_color_symbol_table(color_table[], symbol_table); + free_color_symbol_table(color_table, symbol_table); if (buffer) free(buffer); if (image) @@ -435,7 +435,7 @@ RImage *RLoadXPM(RContext * context, char *file, int index) bad_file: RErrorCode = RERR_BADIMAGEFILE; fclose(f); - free_color_symbol_table(color_table[], symbol_table); + free_color_symbol_table(color_table, symbol_table); if (buffer) free(buffer); if (image)