diff options
-rw-r--r-- | other/pamsplit.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/other/pamsplit.c b/other/pamsplit.c index 2c64d1a0..2c029d04 100644 --- a/other/pamsplit.c +++ b/other/pamsplit.c @@ -16,10 +16,10 @@ #include <stdio.h> #include "pm_c_util.h" -#include "pam.h" #include "shhopt.h" #include "nstring.h" #include "mallocvar.h" +#include "pam.h" struct cmdlineInfo { /* All the information the user supplied in the command line, @@ -34,7 +34,7 @@ struct cmdlineInfo { static void -parseCommandLine(int argc, char ** argv, +parseCommandLine(int argc, const char ** argv, struct cmdlineInfo * const cmdlineP) { /*---------------------------------------------------------------------------- Note that the pointers we place into *cmdlineP are sometimes to storage @@ -59,7 +59,7 @@ parseCommandLine(int argc, char ** argv, opt.short_allowed = FALSE; /* We have no short (old-fashioned) options */ opt.allowNegNum = FALSE; /* We have no parms that are negative numbers */ - pm_optParseOptions3(&argc, argv, opt, sizeof(opt), 0); + pm_optParseOptions3(&argc, (char **)argv, opt, sizeof(opt), 0); /* Uses and sets argc, argv, and some of *cmdlineP and others. */ if (!padnameSpec) @@ -150,7 +150,7 @@ computeOutputName(char const outputFilePattern[], int -main(int argc, char *argv[]) { +main(int argc, const char *argv[]) { struct cmdlineInfo cmdline; @@ -159,7 +159,7 @@ main(int argc, char *argv[]) { unsigned int imageSeq; /* Sequence of current image in input file. First = 0 */ - pnm_init(&argc, argv); + pm_proginit(&argc, argv); parseCommandLine(argc, argv, &cmdline); @@ -187,3 +187,6 @@ main(int argc, char *argv[]) { return 0; } + + + |