You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-15 14:13:16 +02:00
avcodec/proresenc_anatoliy: check against maximum dimensions
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
@@ -554,6 +554,12 @@ static av_cold int prores_encode_init(AVCodecContext *avctx)
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (avctx->width > 65534 || avctx->height > 65535) {
|
||||||
|
av_log(avctx, AV_LOG_ERROR,
|
||||||
|
"The maximum dimensions are 65534x65535\n");
|
||||||
|
return AVERROR(EINVAL);
|
||||||
|
}
|
||||||
|
|
||||||
if ((avctx->height & 0xf) || (avctx->width & 0xf)) {
|
if ((avctx->height & 0xf) || (avctx->width & 0xf)) {
|
||||||
ctx->fill_y = av_malloc(4 * (DEFAULT_SLICE_MB_WIDTH << 8));
|
ctx->fill_y = av_malloc(4 * (DEFAULT_SLICE_MB_WIDTH << 8));
|
||||||
if (!ctx->fill_y)
|
if (!ctx->fill_y)
|
||||||
|
Reference in New Issue
Block a user