aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/flvdec.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-04-24 21:34:30 +0200
committerMichael Niedermayer <michaelni@gmx.at>2014-04-24 21:37:26 +0200
commit7da5ff5c18ae3f9d0943e41fb637a6ebefa9277f (patch)
tree5ca70af135d1854d40788c3e0d9411301c9841ea /libavformat/flvdec.c
parent277ae5a7b30496eabfb35b4dd6a62a335a422085 (diff)
parent5d983fdbca5570a1545a892583a372cfb3fffe92 (diff)
downloadffmpeg-7da5ff5c18ae3f9d0943e41fb637a6ebefa9277f.tar.gz
Merge commit '5d983fdbca5570a1545a892583a372cfb3fffe92'
* commit '5d983fdbca5570a1545a892583a372cfb3fffe92': flv: Warn only once Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/flvdec.c')
-rw-r--r--libavformat/flvdec.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/libavformat/flvdec.c b/libavformat/flvdec.c
index 41f9380620..c19c2d663a 100644
--- a/libavformat/flvdec.c
+++ b/libavformat/flvdec.c
@@ -934,10 +934,11 @@ retry_duration:
// sign extension
int32_t cts = (avio_rb24(s->pb) + 0xff800000) ^ 0xff800000;
pts = dts + cts;
- if (cts < 0) { // dts are wrong
+ if (cts < 0) { // dts might be wrong
+ if (!flv->wrong_dts)
+ av_log(s, AV_LOG_WARNING,
+ "Negative cts, previous timestamps might be wrong.\n");
flv->wrong_dts = 1;
- av_log(s, AV_LOG_WARNING,
- "Negative cts, previous timestamps might be wrong.\n");
} else if (FFABS(dts - pts) > 1000*60*15) {
av_log(s, AV_LOG_WARNING,
"invalid timestamps %"PRId64" %"PRId64"\n", dts, pts);