mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-01-13 21:28:01 +02:00
huffyuv: Check memory allocation
This commit is contained in:
parent
7fccc96dc3
commit
7d2a682691
@ -155,7 +155,7 @@ static av_cold int encode_init(AVCodecContext *avctx)
|
|||||||
s->version = 2;
|
s->version = 2;
|
||||||
|
|
||||||
avctx->coded_frame = av_frame_alloc();
|
avctx->coded_frame = av_frame_alloc();
|
||||||
if (!avctx->coded_frame)
|
if (!avctx->extradata || !avctx->stats_out || !avctx->coded_frame)
|
||||||
return AVERROR(ENOMEM);
|
return AVERROR(ENOMEM);
|
||||||
|
|
||||||
avctx->coded_frame->pict_type = AV_PICTURE_TYPE_I;
|
avctx->coded_frame->pict_type = AV_PICTURE_TYPE_I;
|
||||||
|
Loading…
Reference in New Issue
Block a user