From b01e6a7e0b961d44138bf683713563ac0fedac32 Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Fri, 3 May 2024 21:51:42 +0200 Subject: [PATCH] avcodec/decode: decode_simple_internal() only implements audio and video Fixes: CID1538861 Uninitialized scalar variable Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer (cherry picked from commit e9bb586543d83fe0ed901834b853b6d64e327529) Signed-off-by: Michael Niedermayer --- libavcodec/decode.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libavcodec/decode.c b/libavcodec/decode.c index 34bcb7cc64..ac18544b2e 100644 --- a/libavcodec/decode.c +++ b/libavcodec/decode.c @@ -428,7 +428,8 @@ FF_ENABLE_DEPRECATION_WARNINGS } else if (avctx->codec->type == AVMEDIA_TYPE_AUDIO) { ret = !got_frame ? AVERROR(EAGAIN) : discard_samples(avctx, frame, discarded_samples); - } + } else + av_assert0(0); if (ret == AVERROR(EAGAIN)) av_frame_unref(frame);