]> git.sesse.net Git - ffmpeg/blobdiff - libavformat/wavdec.c
avformat/hlsenc: donnot show duplicate segment warning at byterange mode
[ffmpeg] / libavformat / wavdec.c
index 602ce975302e11bcb69cb98db7b9f4a8b05149e1..81dbc9f16e16782c1ebaee670503a236e892d612 100644 (file)
@@ -841,6 +841,8 @@ static int w64_read_header(AVFormatContext *s)
                 chunk_key[4] = 0;
                 avio_read(pb, chunk_key, 4);
                 chunk_size = avio_rl32(pb);
+                if (chunk_size == UINT32_MAX)
+                    return AVERROR_INVALIDDATA;
 
                 value = av_mallocz(chunk_size + 1);
                 if (!value)