mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
bfi: check return value of av_malloc()
Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
parent
b791a0831b
commit
51f1bf3309
@ -81,6 +81,8 @@ static int bfi_read_header(AVFormatContext * s)
|
||||
/*Load the palette to extradata */
|
||||
avio_skip(pb, 8);
|
||||
vstream->codec->extradata = av_malloc(768);
|
||||
if (!vstream->codec->extradata)
|
||||
return AVERROR(ENOMEM);
|
||||
vstream->codec->extradata_size = 768;
|
||||
avio_read(pb, vstream->codec->extradata,
|
||||
vstream->codec->extradata_size);
|
||||
|
Loading…
Reference in New Issue
Block a user