mirror of
https://github.com/xenia-project/FFmpeg.git
synced 2024-11-25 04:30:02 +00:00
asv: Check memory allocation
This commit is contained in:
parent
074a1b3732
commit
e524f37356
@ -299,6 +299,8 @@ static av_cold int encode_init(AVCodecContext *avctx)
|
||||
avctx->global_quality / 2) / avctx->global_quality;
|
||||
|
||||
avctx->extradata = av_mallocz(8);
|
||||
if (!avctx->extradata)
|
||||
return AVERROR(ENOMEM);
|
||||
avctx->extradata_size = 8;
|
||||
((uint32_t *) avctx->extradata)[0] = av_le2ne32(a->inv_qscale);
|
||||
((uint32_t *) avctx->extradata)[1] = av_le2ne32(AV_RL32("ASUS"));
|
||||
|
Loading…
Reference in New Issue
Block a user