Commit 9889762a authored by Michael Niedermayer's avatar Michael Niedermayer

Merge commit 'ae5e1f3d'

* commit 'ae5e1f3d':
  tiff: Check that there is no aliasing in pixel format selection

See: e1c0cfaaMerged-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parents 1b47760b ae5e1f3d
......@@ -658,6 +658,14 @@ static int init_image(TiffContext *s, ThreadFrame *frame)
int ret;
int create_gray_palette = 0;
// make sure there is no aliasing in the following switch
if (s->bpp >= 100 || s->bppcount >= 10) {
av_log(s->avctx, AV_LOG_ERROR,
"Unsupported image parameters: bpp=%d, bppcount=%d\n",
s->bpp, s->bppcount);
return AVERROR_INVALIDDATA;
}
switch (s->planar * 1000 + s->bpp * 10 + s->bppcount) {
case 11:
if (!s->palette_is_set) {
......
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