Message ID | 20230105110756.473-2-anton@khirnov.net |
---|---|
State | Accepted |
Commit | 5bf8f29135a6fd3fb2e887c7a37f3594eff97db8 |
Headers | show |
Series | [FFmpeg-devel,1/4] lavc/ac3dec: fail when the sample rate is unset | expand |
Context | Check | Description |
---|---|---|
yinshiyou/make_loongarch64 | success | Make finished |
yinshiyou/make_fate_loongarch64 | success | Make fate finished |
andriy/make_x86 | success | Make finished |
andriy/make_fate_x86 | success | Make fate finished |
On Do, 2023-01-05 at 12:07 +0100, Anton Khirnov wrote: > --- > 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; LGTM, thx -Haihao
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;