Mercurial > libavcodec.hg
changeset 9530:dbb16aa52d43 libavcodec
mlpdec: Restart header sync must be 0x31ea for MLP.
author | ramiro |
---|---|
date | Tue, 21 Apr 2009 21:57:23 +0000 |
parents | e885f6298a7a |
children | 19a70bcc2220 |
files | mlpdec.c |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/mlpdec.c Tue Apr 21 21:51:01 2009 +0000 +++ b/mlpdec.c Tue Apr 21 21:57:23 2009 +0000 @@ -337,13 +337,14 @@ int start_count = get_bits_count(gbp); sync_word = get_bits(gbp, 13); + s->noise_type = get_bits1(gbp); - if (sync_word != 0x31ea >> 1) { + if ((m->avctx->codec_id == CODEC_ID_MLP && s->noise_type) || + sync_word != 0x31ea >> 1) { av_log(m->avctx, AV_LOG_ERROR, "restart header sync incorrect (got 0x%04x)\n", sync_word); return -1; } - s->noise_type = get_bits1(gbp); skip_bits(gbp, 16); /* Output timestamp */