summaryrefslogtreecommitdiff
path: root/libavformat/dtsdec.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-08-02 17:25:04 +0200
committerMichael Niedermayer <michaelni@gmx.at>2014-08-02 17:25:04 +0200
commit2b501b553f6300bfec546fe81d2bc0473e43e223 (patch)
tree8f73c6f923590b2c9e80e186c04f1b335393e0a1 /libavformat/dtsdec.c
parente6fabd6e9bfdb6d010da7e61d32ad1e558703654 (diff)
avformat/dtsdec: skip the first 4k in dts_probe()
DTS primarly needs to be separated from PCM, and PCM can contain cliping and overshoots at the very start which can mimic DTS headers. If this isnt sufficient then more of the DTS stream has to be decoded and analyzed Fixes ticket3784 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/dtsdec.c')
-rw-r--r--libavformat/dtsdec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/dtsdec.c b/libavformat/dtsdec.c
index 330c428516..0ebf8472c5 100644
--- a/libavformat/dtsdec.c
+++ b/libavformat/dtsdec.c
@@ -36,7 +36,7 @@ static int dts_probe(AVProbeData *p)
int sum, max, i;
int64_t diff = 0;
- buf = p->buf;
+ buf = p->buf + FFMIN(4096, p->buf_size);
for(; buf < (p->buf+p->buf_size)-2; buf+=2) {
bufp = buf;