Commit febf75f3 authored by ami_stuff's avatar ami_stuff Committed by Carl Eugen Hoyos

pam: Reject 64bpp rgba.

Fixes ticket #883
parent 09f25a9c
......@@ -125,7 +125,12 @@ int ff_pnm_decode_header(AVCodecContext *avctx, PNMContext * const s)
avctx->pix_fmt = PIX_FMT_RGB48BE;
}
} else if (depth == 4) {
if (maxval < 256) {
avctx->pix_fmt = PIX_FMT_RGB32;
} else {
av_log(avctx, AV_LOG_ERROR, "Unsupported bit depth\n");
return -1;
}
} else {
return -1;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment