[FFmpeg-cvslog] r14528 - trunk/libavcodec/ac3dec.c
jbr
subversion
Mon Aug 4 00:29:06 CEST 2008
Author: jbr
Date: Mon Aug 4 00:29:06 2008
New Revision: 14528
Log:
Read bitstream parameters for E-AC-3 streams before returning an error.
Modified:
trunk/libavcodec/ac3dec.c
Modified: trunk/libavcodec/ac3dec.c
==============================================================================
--- trunk/libavcodec/ac3dec.c (original)
+++ trunk/libavcodec/ac3dec.c Mon Aug 4 00:29:06 2008
@@ -283,9 +283,6 @@ static int parse_frame_header(AC3DecodeC
if(err)
return err;
- if(hdr.bitstream_id > 10)
- return AC3_PARSE_ERROR_BSID;
-
/* get decoding parameters from header info */
s->bit_alloc_params.sr_code = hdr.sr_code;
s->channel_mode = hdr.channel_mode;
@@ -310,6 +307,9 @@ static int parse_frame_header(AC3DecodeC
s->channel_in_cpl[s->lfe_ch] = 0;
}
+ if(hdr.bitstream_id > 10)
+ return AC3_PARSE_ERROR_BSID;
+
return ac3_parse_header(s);
}
More information about the ffmpeg-cvslog
mailing list