wrlib: Marked args as unused for compiler

The two functions require an argument which is used when the libXpm is
used, which means having the same argument list for the builtin code to be
permutable.

This patch adds the appropriate stuff to avoid a false report from the
compiler.

Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
This commit is contained in:
Christophe CURIS authored and Carlos R. Mafra committed 2013-12-30 18:11:03 +00:00
1 parent 3b2362662e
commit f619546af9
1 file changed
+12
+12
View File
@@ -80,6 +80,12 @@ RImage *RGetImageFromXPMData(RContext * context, char **data)
int bsize;
int w, h, ccount, csize;
/*
* When using libXpm we need the context argument but the code here does
* not, so tell the compiler to not warn about it
*/
(void) context;
if (sscanf(data[line++], "%i %i %i %i", &w, &h, &ccount, &csize) != 4
|| w <= 0 || h <= 0 || ccount <= 0 || csize <= 0)
goto bad_format;
@@ -242,6 +248,12 @@ RImage *RLoadXPM(RContext * context, const char *file)
int w, h, ccount, csize;
FILE *f;
/*
* When using libXpm we need the context argument but the code here does
* not, so tell the compiler to not warn about it
*/
(void) context;
f = fopen(file, "rb");
if (!f) {
RErrorCode = RERR_OPEN;