mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-12-12 01:40:04 +01:00
avformat: use ff_alloc_extradata()
Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
@@ -113,9 +113,7 @@ static int redspark_read_header(AVFormatContext *s)
|
||||
goto fail;
|
||||
}
|
||||
|
||||
codec->extradata_size = 32 * codec->channels;
|
||||
codec->extradata = av_malloc(codec->extradata_size);
|
||||
if (!codec->extradata) {
|
||||
if (ff_alloc_extradata(codec, 32 * codec->channels)) {
|
||||
ret = AVERROR(ENOMEM);
|
||||
goto fail;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user