[FFmpeg-cvslog] avidec/guess_ni_flag: fix harmless integer overflow

Michael Niedermayer git at videolan.org
Mon Sep 10 17:01:51 CEST 2012


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Mon Sep 10 16:56:59 2012 +0200| [108957c661f9e2dc35dea8d55e5e5b1776f4a303] | committer: Michael Niedermayer

avidec/guess_ni_flag: fix harmless integer overflow

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=108957c661f9e2dc35dea8d55e5e5b1776f4a303
---

 libavformat/avidec.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/avidec.c b/libavformat/avidec.c
index 5abb9de..3e85d4e 100644
--- a/libavformat/avidec.c
+++ b/libavformat/avidec.c
@@ -1341,7 +1341,7 @@ static int guess_ni_flag(AVFormatContext *s){
     if (last_start > first_end)
         return 1;
     idx= av_mallocz(sizeof(*idx) * s->nb_streams);
-    for (min_pos=pos=0; min_pos!=INT64_MAX; pos= min_pos+1) {
+    for (min_pos=pos=0; min_pos!=INT64_MAX; pos= min_pos+1LU) {
         int64_t max_dts = INT64_MIN/2, min_dts= INT64_MAX/2;
         min_pos = INT64_MAX;
 



More information about the ffmpeg-cvslog mailing list