Commit dd36d2a1 authored by bcoudurier's avatar bcoudurier

10l, protect malloc overflow

git-svn-id: file:///var/local/repositories/ffmpeg/trunk@12205 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 4e5640d5
......@@ -368,6 +368,8 @@ static int aiff_read_header(AVFormatContext *s,
url_fskip(pb, size - 8);
break;
case MKTAG('w', 'a', 'v', 'e'):
if ((uint64_t)size > (1<<30))
return -1;
st->codec->extradata = av_mallocz(size + FF_INPUT_BUFFER_PADDING_SIZE);
if (!st->codec->extradata)
return AVERROR(ENOMEM);
......
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