diff --git a/libavcodec/pnm.c b/libavcodec/pnm.c index ac451ca5ed..fa43c8d6e9 100644 --- a/libavcodec/pnm.c +++ b/libavcodec/pnm.c @@ -113,9 +113,9 @@ int ff_pnm_decode_header(AVCodecContext *avctx, PNMContext * const s) if (depth == 1) { if (maxval == 1) { avctx->pix_fmt = PIX_FMT_MONOWHITE; - } else if (maxval == 255) { + } else if (maxval == 255) { avctx->pix_fmt = PIX_FMT_GRAY8; - } else { + } else { avctx->pix_fmt = PIX_FMT_GRAY16BE; } } else if (depth == 3) {