aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnssi Hannula <anssi.hannula@iki.fi>2013-10-29 22:25:27 +0200
committerMichael Niedermayer <michaelni@gmx.at>2013-11-17 19:11:07 +0100
commitb56e9beeb83898a8531d2e3f2105a9b65c94cf21 (patch)
tree1777b1e1187d1e5e8d49ef54347f0bca844a2f95
parentd8be5bda1b96e9cf3e14f7940105c954543ca905 (diff)
downloadffmpeg-b56e9beeb83898a8531d2e3f2105a9b65c94cf21.tar.gz
lavf/spdifdec: fix demuxing of AAC in IEC 61937
Return value of avpriv_aac_parse_header() is not checked correctly. Fix it. Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi> Signed-off-by: Michael Niedermayer <michaelni@gmx.at> (cherry picked from commit f86387b6c2b11650cb9d5a8fd886be76e48c665b) Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavformat/spdifdec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/spdifdec.c b/libavformat/spdifdec.c
index 69843503b0..7da16c95ba 100644
--- a/libavformat/spdifdec.c
+++ b/libavformat/spdifdec.c
@@ -57,7 +57,7 @@ static int spdif_get_offset_and_codec(AVFormatContext *s,
break;
case IEC61937_MPEG2_AAC:
init_get_bits(&gbc, buf, AAC_ADTS_HEADER_SIZE * 8);
- if (avpriv_aac_parse_header(&gbc, &aac_hdr)) {
+ if (avpriv_aac_parse_header(&gbc, &aac_hdr) < 0) {
if (s) /* be silent during a probe */
av_log(s, AV_LOG_ERROR, "Invalid AAC packet in IEC 61937\n");
return AVERROR_INVALIDDATA;