diff options
Diffstat (limited to 'converter/other/giftopnm.c')
-rw-r--r-- | converter/other/giftopnm.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/converter/other/giftopnm.c b/converter/other/giftopnm.c index bc1d545a..c1c79e26 100644 --- a/converter/other/giftopnm.c +++ b/converter/other/giftopnm.c @@ -1449,20 +1449,14 @@ pnmFormat(bool const hasGray, by 'hasGray' and 'hasColor'. -----------------------------------------------------------------------------*/ int format; - const char * formatName; if (hasColor) { format = PPM_FORMAT; - formatName = "PPM"; } else if (hasGray) { format = PGM_FORMAT; - formatName = "PGM"; } else { format = PBM_FORMAT; - formatName = "PBM"; } - if (verbose) - pm_message("writing a %s file", formatName); return format; } @@ -1555,6 +1549,9 @@ convertRaster(Decompressor * const decompP, MALLOCARRAY2(cmapIndexArray, interlace ? rows : 1 , cols); + if (verbose) + pm_message("writing a %s file", pnm_formattypenm(format)); + if (imageOutFileP) pnm_writepnminit(imageOutFileP, cols, rows, GIFMAXVAL, format, false); if (alphaFileP) |