]> git.sesse.net Git - ffmpeg/blobdiff - libavformat/smacker.c
avformat/avformat: Constify AVFormatContext.*_codec pointers
[ffmpeg] / libavformat / smacker.c
index 9966a670553ce82f89cb99ca8d3f7a926185780a..61209e7038481b35d2e8359b44153eda31af42f4 100644 (file)
@@ -105,8 +105,8 @@ static int smacker_read_header(AVFormatContext *s)
     height = avio_rl32(pb);
     smk->frames = avio_rl32(pb);
     pts_inc = avio_rl32(pb);
-    if (pts_inc > INT_MAX / 100) {
-        av_log(s, AV_LOG_ERROR, "pts_inc %d is too large\n", pts_inc);
+    if (pts_inc > INT_MAX / 100 || pts_inc == INT_MIN) {
+        av_log(s, AV_LOG_ERROR, "pts_inc %d is invalid\n", pts_inc);
         return AVERROR_INVALIDDATA;
     }