[FFmpeg-cvslog] avformat/matroskadec: Assert that num_levels is non negative
Michael Niedermayer
git at videolan.org
Thu Jun 13 23:42:20 EEST 2024
ffmpeg | branch: release/5.1 | Michael Niedermayer <michael at niedermayer.cc> | Mon Jun 3 01:25:59 2024 +0200| [e0e1a3893d1fba0721fc348831f269a5206cb4f1] | committer: Michael Niedermayer
avformat/matroskadec: Assert that num_levels is non negative
Maybe Closes: CID1452496 Uninitialized scalar variable
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
(cherry picked from commit 019fce18bb0628ac8bc47a81d647a23d604b6123)
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=e0e1a3893d1fba0721fc348831f269a5206cb4f1
---
libavformat/matroskadec.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c
index 3d85e63ca9..9a3615812e 100644
--- a/libavformat/matroskadec.c
+++ b/libavformat/matroskadec.c
@@ -3848,7 +3848,7 @@ static int matroska_parse_cluster(MatroskaDemuxContext *matroska)
MatroskaBlock *block = &cluster->block;
int res;
- av_assert0(matroska->num_levels <= 2);
+ av_assert0(matroska->num_levels <= 2U);
if (matroska->num_levels == 1) {
res = ebml_parse(matroska, matroska_segment, NULL);
More information about the ffmpeg-cvslog
mailing list