1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-11-26 19:01:44 +02:00

avcodec/cfhdenc: height < 4 is not supported

This commit is contained in:
Paul B Mahol 2022-12-01 19:27:35 +01:00
parent 4d38d4607c
commit 0d6a6c8750

View File

@ -258,6 +258,11 @@ static av_cold int cfhd_encode_init(AVCodecContext *avctx)
if (ret < 0)
return ret;
if (avctx->height < 4) {
av_log(avctx, AV_LOG_ERROR, "Height must be >= 4.\n");
return AVERROR_INVALIDDATA;
}
if (avctx->width & 15) {
av_log(avctx, AV_LOG_ERROR, "Width must be multiple of 16.\n");
return AVERROR_INVALIDDATA;