diff options
Diffstat (limited to 'converter/ppm')
-rw-r--r-- | converter/ppm/ximtoppm.c | 4 | ||||
-rw-r--r-- | converter/ppm/xvminitoppm.c | 8 |
2 files changed, 8 insertions, 4 deletions
diff --git a/converter/ppm/ximtoppm.c b/converter/ppm/ximtoppm.c index 98aad2d7..15589c16 100644 --- a/converter/ppm/ximtoppm.c +++ b/converter/ppm/ximtoppm.c @@ -52,6 +52,10 @@ parseCommandLine(int argc, char ** argv, OPTENT3(0, "alphaout", OPT_STRING, &cmdlineP->alpha_filename, &alphaoutSpec, 0); + opt.opt_table = option_def; + opt.short_allowed = FALSE; /* We have no short (old-fashioned) options */ + opt.allowNegNum = FALSE; /* We have no parms that are negative numbers */ + optParseOptions3(&argc, argv, opt, sizeof(opt), 0); /* Uses and sets argc, argv, and all of *cmdlineP. */ diff --git a/converter/ppm/xvminitoppm.c b/converter/ppm/xvminitoppm.c index 16626bc2..d76bea87 100644 --- a/converter/ppm/xvminitoppm.c +++ b/converter/ppm/xvminitoppm.c @@ -53,7 +53,7 @@ parseCommandLine(int const argc, static void -getline(FILE * const ifP, +getLine(FILE * const ifP, char * const buf, size_t const size) { @@ -107,7 +107,7 @@ readXvHeader(FILE * const ifP, int rc; bool endOfComments; - getline(ifP, buf, sizeof(buf)); + getLine(ifP, buf, sizeof(buf)); if (!strneq(buf, "P7 332", 6)) pm_error("Input is not a XV thumbnail picture. It does not " @@ -115,14 +115,14 @@ readXvHeader(FILE * const ifP, endOfComments = FALSE; while (!endOfComments) { - getline(ifP, buf, sizeof(buf)); + getLine(ifP, buf, sizeof(buf)); if (strneq(buf, "#END_OF_COMMENTS", 16)) endOfComments = TRUE; else if (strneq(buf, "#BUILTIN", 8)) pm_error("This program does not know how to " "convert builtin XV thumbnail pictures"); } - getline(ifP, buf, sizeof(buf)); + getLine(ifP, buf, sizeof(buf)); rc = sscanf(buf, "%u %u %u", &cols, &rows, &maxval); if (rc != 3) pm_error("error parsing dimension info '%s'. " |