|
|
987d884 |
diff --git a/converter/pbm/cmuwmtopbm.c b/converter/pbm/cmuwmtopbm.c
|
|
|
987d884 |
index 5c138c1..1f9bc6c 100644
|
|
|
987d884 |
--- a/converter/pbm/cmuwmtopbm.c
|
|
|
987d884 |
+++ b/converter/pbm/cmuwmtopbm.c
|
|
|
987d884 |
@@ -48,20 +48,20 @@ readCmuwmHeader(FILE * const ifP,
|
|
|
987d884 |
|
|
|
987d884 |
rc = pm_readbiglong(ifP, &l);
|
|
|
987d884 |
if (rc == -1 )
|
|
|
987d884 |
- pm_error(initReadError);
|
|
|
987d884 |
+ pm_error("%s", initReadError);
|
|
|
987d884 |
if ((uint32_t)l != cmuwmMagic)
|
|
|
987d884 |
pm_error("bad magic number in CMU window manager file");
|
|
|
987d884 |
rc = pm_readbiglong(ifP, &l);
|
|
|
987d884 |
if (rc == -1)
|
|
|
987d884 |
- pm_error(initReadError);
|
|
|
987d884 |
+ pm_error("%s", initReadError);
|
|
|
987d884 |
*colsP = l;
|
|
|
987d884 |
rc = pm_readbiglong(ifP, &l);
|
|
|
987d884 |
if (rc == -1 )
|
|
|
987d884 |
- pm_error(initReadError);
|
|
|
987d884 |
+ pm_error("%s", initReadError);
|
|
|
987d884 |
*rowsP = l;
|
|
|
987d884 |
rc = pm_readbigshort(ifP, &s);
|
|
|
987d884 |
if (rc == -1)
|
|
|
987d884 |
- pm_error(initReadError);
|
|
|
987d884 |
+ pm_error("%s", initReadError);
|
|
|
987d884 |
*depthP = s;
|
|
|
987d884 |
}
|
|
|
987d884 |
|
|
|
987d884 |
diff --git a/converter/other/tifftopnm.c b/converter/other/tifftopnm.c
|
|
|
987d884 |
index 3aa2e43..b8ebf39 100644
|
|
|
987d884 |
--- a/converter/other/tifftopnm.c
|
|
|
987d884 |
+++ b/converter/other/tifftopnm.c
|
|
|
987d884 |
@@ -1459,7 +1459,7 @@ convertRasterInMemory(pnmOut * const pnmOutP,
|
|
|
987d884 |
int ok;
|
|
|
987d884 |
ok = TIFFRGBAImageOK(tif, emsg);
|
|
|
987d884 |
if (!ok) {
|
|
|
987d884 |
- pm_message(emsg);
|
|
|
987d884 |
+ pm_message("%s", emsg);
|
|
|
987d884 |
*statusP = CONV_UNABLE;
|
|
|
987d884 |
} else {
|
|
|
987d884 |
uint32 * raster;
|
|
|
987d884 |
@@ -1479,14 +1479,14 @@ convertRasterInMemory(pnmOut * const pnmOutP,
|
|
|
987d884 |
|
|
|
987d884 |
ok = TIFFRGBAImageBegin(&img, tif, stopOnErrorFalse, emsg);
|
|
|
987d884 |
if (!ok) {
|
|
|
987d884 |
- pm_message(emsg);
|
|
|
987d884 |
+ pm_message("%s", emsg);
|
|
|
987d884 |
*statusP = CONV_FAILED;
|
|
|
987d884 |
} else {
|
|
|
987d884 |
int ok;
|
|
|
987d884 |
ok = TIFFRGBAImageGet(&img, raster, cols, rows);
|
|
|
987d884 |
TIFFRGBAImageEnd(&img) ;
|
|
|
987d884 |
if (!ok) {
|
|
|
987d884 |
- pm_message(emsg);
|
|
|
987d884 |
+ pm_message("%s", emsg);
|
|
|
987d884 |
*statusP = CONV_FAILED;
|
|
|
987d884 |
} else {
|
|
|
987d884 |
*statusP = CONV_DONE;
|
|
|
987d884 |
diff --git a/lib/util/pm_c_util.h b/lib/util/pm_c_util.h
|
|
|
987d884 |
index 01a0765..8f5aa01 100644
|
|
|
987d884 |
--- a/lib/util/pm_c_util.h
|
|
|
987d884 |
+++ b/lib/util/pm_c_util.h
|
|
|
987d884 |
@@ -80,10 +80,10 @@
|
|
|
987d884 |
#endif
|
|
|
987d884 |
|
|
|
987d884 |
#ifndef TRUE
|
|
|
987d884 |
- #define TRUE true
|
|
|
987d884 |
+ #define TRUE 1
|
|
|
987d884 |
#endif
|
|
|
987d884 |
#ifndef FALSE
|
|
|
987d884 |
- #define FALSE false
|
|
|
987d884 |
+ #define FALSE 0
|
|
|
987d884 |
#endif
|
|
|
987d884 |
|
|
|
987d884 |
#define ARRAY_SIZE(x) (sizeof(x)/sizeof(x[0]))
|
|
|
987d884 |
diff --git a/converter/other/fiasco/pnmtofiasco.c b/converter/other/fiasco/pnmtofiasco.c
|
|
|
987d884 |
index d78ff6b..761dac5 100644
|
|
|
987d884 |
--- a/converter/other/fiasco/pnmtofiasco.c
|
|
|
987d884 |
+++ b/converter/other/fiasco/pnmtofiasco.c
|
|
|
987d884 |
@@ -170,7 +170,7 @@ main (int argc, char **argv)
|
|
|
987d884 |
return 0;
|
|
|
987d884 |
else
|
|
|
987d884 |
{
|
|
|
987d884 |
- fprintf (stderr, fiasco_get_error_message ());
|
|
|
987d884 |
+ fprintf (stderr, "%s", fiasco_get_error_message ());
|
|
|
987d884 |
fprintf (stderr, "\n");
|
|
|
987d884 |
return 1;
|
|
|
987d884 |
}
|
|
|
987d884 |
diff --git a/converter/other/fiasco/params.c b/converter/other/fiasco/params.c
|
|
|
987d884 |
index a4d843a..9659e9f 100644
|
|
|
987d884 |
--- a/converter/other/fiasco/params.c
|
|
|
987d884 |
+++ b/converter/other/fiasco/params.c
|
|
|
987d884 |
@@ -656,7 +656,7 @@ usage (const param_t *params, const char *progname, const char *synopsis,
|
|
|
987d884 |
fprintf (stderr, "Usage: %s [OPTION]...%s\n", progname,
|
|
|
987d884 |
non_opt_string ? non_opt_string : " ");
|
|
|
987d884 |
if (synopsis != NULL)
|
|
|
987d884 |
- fprintf (stderr, synopsis);
|
|
|
987d884 |
+ fprintf (stderr, "%s\n", synopsis);
|
|
|
987d884 |
fprintf (stderr, "\n\n");
|
|
|
987d884 |
fprintf (stderr, "Mandatory or optional arguments to long options "
|
|
|
987d884 |
"are mandatory or optional\nfor short options too. "
|