summaryrefslogtreecommitdiff
path: root/libavformat
diff options
context:
space:
mode:
authorSean McGovern <gseanmcg@gmail.com>2017-07-29 19:17:16 -0400
committerSean McGovern <gseanmcg@gmail.com>2017-07-31 17:41:01 -0400
commitdefe307fb22beca60a632e976ab97e5edd4aee25 (patch)
tree21c94701223fc62fe067127fe28d2bfe5a4e27e5 /libavformat
parent3050dabaa9a337ad077ec60bba664ad9861e1aa6 (diff)
downloadffmpeg-defe307fb22beca60a632e976ab97e5edd4aee25.tar.gz
mov: move stsd finalization to an appropriate place
mov_finalize_stsd_codec() parses stream information from the ALAC extradata, so run it after the extradata processing is completed in mov_read_stsd(). Fixes playback of 96kHz ALAC streams muxed by qaac or the reference alac encoder. Adapted from an FFmpeg patch by Hendrik Leppkes <h.leppkes@gmail.com> Bug-Id: 1072
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/mov.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavformat/mov.c b/libavformat/mov.c
index 2134bd1743..6711d8e11e 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -1857,7 +1857,7 @@ int ff_mov_read_stsd_entries(MOVContext *c, AVIOContext *pb, int entries)
if (pb->eof_reached)
return AVERROR_EOF;
- return mov_finalize_stsd_codec(c, pb, st, sc);
+ return 0;
}
static int mov_read_stsd(MOVContext *c, AVIOContext *pb, MOVAtom atom)
@@ -1913,7 +1913,7 @@ static int mov_read_stsd(MOVContext *c, AVIOContext *pb, MOVAtom atom)
}
memcpy(st->codecpar->extradata, sc->extradata[0], sc->extradata_size[0]);
- return 0;
+ return mov_finalize_stsd_codec(c, pb, st, sc);
fail:
av_freep(&sc->extradata);
av_freep(&sc->extradata_size);