Commit 5badcfe2 authored by Michael Niedermayer's avatar Michael Niedermayer

Merge commit 'd07aa3f0'

* commit 'd07aa3f0':
  riffdec: Add sanity checks for the sample rate
Merged-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parents a89e9ad1 d07aa3f0
......@@ -130,6 +130,11 @@ int ff_get_wav_header(AVIOContext *pb, AVCodecContext *codec, int size)
if (size > 0)
avio_skip(pb, size);
}
if (codec->sample_rate <= 0) {
av_log(NULL, AV_LOG_ERROR,
"Invalid sample rate: %d\n", codec->sample_rate);
return AVERROR_INVALIDDATA;
}
if (codec->codec_id == AV_CODEC_ID_AAC_LATM) {
/* Channels and sample_rate values are those prior to applying SBR
* and/or PS. */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment