Browse Source

avformat/mpegts: print packet size warning only if new size differs from old

No case is known to have triggered this, but its more correct to check that the
new size differs.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Michael Niedermayer 11 years ago
parent
commit
ee7f2609a0
1 changed files with 1 additions and 1 deletions
  1. 1 1
      libavformat/mpegts.c

+ 1 - 1
libavformat/mpegts.c

@@ -1929,7 +1929,7 @@ static void reanalyze(MpegTSContext *ts) {
         } else if (ts->size_stat[2] > SIZE_STAT_THRESHOLD) {
             newsize = TS_FEC_PACKET_SIZE;
         }
-        if (newsize) {
+        if (newsize && newsize != ts->raw_packet_size) {
             av_log(ts->stream, AV_LOG_WARNING, "changing packet size to %d\n", newsize);
             ts->raw_packet_size = newsize;
         }