Merge commit '747fbe0c212b81952bb27ec7b99fa709081e2d63' into release/1.1
* commit '747fbe0c212b81952bb27ec7b99fa709081e2d63': roqvideodec: fix a potential infinite loop in roqvideo_decode_frame(). mp3dec: Fix VBR bit rate parsing wmaprodec: return an error, not 0, when the input is too small. vmdaudio: fix invalid reads when packet size is not a multiple of chunk size h264: check for luma and chroma bit dept being equal Prepare for 9.4 Release Conflicts: RELEASE libavcodec/vmdav.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
@@ -30,6 +30,7 @@ typedef struct MpegAudioParseContext {
|
||||
int frame_size;
|
||||
uint32_t header;
|
||||
int header_count;
|
||||
int no_bitrate;
|
||||
} MpegAudioParseContext;
|
||||
|
||||
#define MPA_HEADER_SIZE 4
|
||||
@@ -81,7 +82,10 @@ static int mpegaudio_parse(AVCodecParserContext *s1,
|
||||
avctx->sample_rate= sr;
|
||||
avctx->channels = channels;
|
||||
s1->duration = frame_size;
|
||||
avctx->bit_rate = bit_rate;
|
||||
if (s->no_bitrate || !avctx->bit_rate) {
|
||||
s->no_bitrate = 1;
|
||||
avctx->bit_rate += (bit_rate - avctx->bit_rate) / s->header_count;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user