From 5bf8f29135a6fd3fb2e887c7a37f3594eff97db8 Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Thu, 5 Jan 2023 09:50:57 +0100 Subject: [PATCH] lavc/qsvdec: check ff_decode_frame_props() return value --- libavcodec/qsvdec.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libavcodec/qsvdec.c b/libavcodec/qsvdec.c index 92bfea196e..6bc85116ad 100644 --- a/libavcodec/qsvdec.c +++ b/libavcodec/qsvdec.c @@ -128,7 +128,9 @@ static int qsv_get_continuous_buffer(AVCodecContext *avctx, AVFrame *frame, { int ret = 0; - ff_decode_frame_props(avctx, frame); + ret = ff_decode_frame_props(avctx, frame); + if (ret < 0) + return ret; frame->width = avctx->width; frame->height = avctx->height;