aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/mpeg.c
diff options
context:
space:
mode:
authorCarl Eugen Hoyos <cehoyos@ag.or.at>2013-01-17 17:19:08 +0100
committerCarl Eugen Hoyos <cehoyos@ag.or.at>2013-01-17 17:19:08 +0100
commitad406f7e402977cb7dbc78ccb63e21c137f6699e (patch)
tree325475daeb6d55f1dbfd25f23c429bfeb390ffdd /libavformat/mpeg.c
parent12cb21efa611e6fd4dc4b9883d85a9f839aad4b7 (diff)
downloadffmpeg-ad406f7e402977cb7dbc78ccb63e21c137f6699e.tar.gz
Only skip MLP header in mpeg files if the codec actually is MLP.
Fixes PCM audio in Kansas Pheasant Hunt 2000 mpg file. Reported-by: Mashiat Sarker Shakkhar
Diffstat (limited to 'libavformat/mpeg.c')
-rw-r--r--libavformat/mpeg.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/mpeg.c b/libavformat/mpeg.c
index cc2fe7f495..4af2057077 100644
--- a/libavformat/mpeg.c
+++ b/libavformat/mpeg.c
@@ -504,7 +504,7 @@ static int mpegps_read_packet(AVFormatContext *s,
if(st->discard >= AVDISCARD_ALL)
goto skip;
if (startcode >= 0xa0 && startcode <= 0xaf) {
- if (lpcm_header_len == 6) {
+ if (lpcm_header_len == 6 && st->codec->codec_id == AV_CODEC_ID_MLP) {
if (len < 6)
goto skip;
avio_skip(s->pb, 6);