From 1056db9bf8ee93c71e66a0ea504c8639cbe7ee79 Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Sun, 19 May 2024 01:20:00 +0200 Subject: [PATCH] avcodec/vvc/dec: Remove constant eos_at_start Fixes: CID1560041 'Constant' variable guards dead code Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer (cherry picked from commit d22a33710acb004f90c7454daf8145c3943ecbeb) Signed-off-by: Michael Niedermayer --- libavcodec/vvc/vvcdec.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/libavcodec/vvc/vvcdec.c b/libavcodec/vvc/vvcdec.c index 46e938bc30..ccb1b59862 100644 --- a/libavcodec/vvc/vvcdec.c +++ b/libavcodec/vvc/vvcdec.c @@ -831,7 +831,6 @@ static int decode_nal_units(VVCContext *s, VVCFrameContext *fc, AVPacket *avpkt) const CodedBitstreamH266Context *h266 = s->cbc->priv_data; CodedBitstreamFragment *frame = &s->current_frame; int ret = 0; - int eos_at_start = 1; s->last_eos = s->eos; s->eos = 0; @@ -847,10 +846,7 @@ static int decode_nal_units(VVCContext *s, VVCFrameContext *fc, AVPacket *avpkt) const CodedBitstreamUnit *unit = frame->units + i; if (unit->type == VVC_EOB_NUT || unit->type == VVC_EOS_NUT) { - if (eos_at_start) - s->last_eos = 1; - else - s->eos = 1; + s->last_eos = 1; } else { ret = decode_nal_unit(s, fc, nal, unit); if (ret < 0) {