diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2011-11-19 20:37:42 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2011-12-16 15:21:19 +0100 |
commit | 388e3e7853d800c53ffcefc187bebb722c31a0fd (patch) | |
tree | 730322cf1ffbdf2e7b89c185b78e529c79e9b28e | |
parent | 866d5c958f24c67127286a82a4d7a730f00253e2 (diff) | |
download | ffmpeg-388e3e7853d800c53ffcefc187bebb722c31a0fd.tar.gz |
ac3dec: update checked AV_EF flags.
A user who wishes to use default error concealment cannot set the
AV_EF_CRCCHECK flag because not every CRC in every format is a
reliable indicator of bitstream damage. In some formats crcrs
can be nonsensical in absence of any damage. We thus add the
AV_EF_CAREFUL flag in addition to the AV_EF_CRCCHECK flag to
allow a user to enable this reliable CRC check without having to
enable all CRC checks in all formats.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit eda3758c87dafe8a6179b16e25e60b11746213ad)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavcodec/ac3dec.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/ac3dec.c b/libavcodec/ac3dec.c index 5e8b36404b..0cb7c67a1f 100644 --- a/libavcodec/ac3dec.c +++ b/libavcodec/ac3dec.c @@ -1371,7 +1371,7 @@ static int ac3_decode_frame(AVCodecContext * avctx, void *data, if (s->frame_size > buf_size) { av_log(avctx, AV_LOG_ERROR, "incomplete frame\n"); err = AAC_AC3_PARSE_ERROR_FRAME_SIZE; - } else if (avctx->err_recognition & AV_EF_CRCCHECK) { + } else if (avctx->err_recognition & (AV_EF_CRCCHECK|AV_EF_CAREFUL)) { /* check for crc mismatch */ if (av_crc(av_crc_get_table(AV_CRC_16_ANSI), 0, &buf[2], s->frame_size - 2)) { |