diff options
Diffstat (limited to 'generator/ppmpat.c')
-rw-r--r-- | generator/ppmpat.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/generator/ppmpat.c b/generator/ppmpat.c index 170bfc58..2f71914e 100644 --- a/generator/ppmpat.c +++ b/generator/ppmpat.c @@ -344,8 +344,8 @@ parseCommandLine(int argc, const char ** argv, pm_error("You must specify 2 non-option arguments: width and height " "in pixels. You specified %u", argc-1); else { - cmdlineP->width = atoi(argv[1]); - cmdlineP->height = atoi(argv[2]); + cmdlineP->width = pm_parse_width(argv[1]); + cmdlineP->height = pm_parse_height(argv[2]); if (cmdlineP->width < 1) pm_error("Width must be at least 1 pixel"); @@ -438,9 +438,6 @@ randomDarkColor(struct pm_randSt * const randStP, - - - static void nextColor(ColorTable * const colorTableP) { /*---------------------------------------------------------------------------- @@ -1654,3 +1651,4 @@ main(int argc, const char ** argv) { } + |