avformat/mov: only force parsing for video tracks if stss is empty
authorHendrik Leppkes <h.leppkes@gmail.com>
Mon, 4 Nov 2013 15:22:27 +0000 (16:22 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Fri, 8 Nov 2013 10:31:02 +0000 (11:31 +0100)
Fixes playback of some AAC streams, which are otherwise mangled by the
parser, and stss is typically only valid for video anyway.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavformat/mov.c

index eec8485..bcdda68 100644 (file)
@@ -1779,7 +1779,7 @@ static int mov_read_stss(MOVContext *c, AVIOContext *pb, MOVAtom atom)
     if (!entries)
     {
         sc->keyframe_absent = 1;
-        if (!st->need_parsing)
+        if (!st->need_parsing && st->codec->codec_type == AVMEDIA_TYPE_VIDEO)
             st->need_parsing = AVSTREAM_PARSE_HEADERS;
         return 0;
     }