diff options
-rw-r--r-- | converter/other/pstopnm.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/converter/other/pstopnm.c b/converter/other/pstopnm.c index 94219c2c..95a97440 100644 --- a/converter/other/pstopnm.c +++ b/converter/other/pstopnm.c @@ -1037,6 +1037,11 @@ main(int argc, char ** argv) { borderedBox = addBorders(extractBox, cmdline.xborder, cmdline.yborder); computeSizeRes(cmdline, borderedBox, &imageDim); + + if (imageDim.xres == 0) + imageDim.xres = 1; + if (imageDim.yres == 0) + imageDim.yres = 1; outfileArg = computeOutfileArg(cmdline); |