diff --git a/libavformat/mpegts.c b/libavformat/mpegts.c index 7a2f9421fe..e8f3889d1a 100644 --- a/libavformat/mpegts.c +++ b/libavformat/mpegts.c @@ -2462,8 +2462,10 @@ static int mpegts_probe(AVProbeData *p) ff_dlog(0, "TS score: %d %d\n", sumscore, maxscore); - if (check_count >= CHECK_COUNT && sumscore > 6) { + if (check_count > CHECK_COUNT && sumscore > 6) { return AVPROBE_SCORE_MAX + sumscore - CHECK_COUNT; + } else if (check_count >= CHECK_COUNT && sumscore > 6) { + return AVPROBE_SCORE_MAX/2 + sumscore - CHECK_COUNT; } else if (check_count >= CHECK_COUNT && maxscore > 6) { return AVPROBE_SCORE_MAX/2 + sumscore - CHECK_COUNT; } else if (sumscore > 6) {