mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
avformat/riffdec: ask for samples with wav header size < 14
Based on commit by Hendrik Leppkes <h.leppkes@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
e4788e9cd9
commit
e74f2be1ed
@ -84,6 +84,9 @@ int ff_get_wav_header(AVIOContext *pb, AVCodecContext *codec, int size)
|
|||||||
{
|
{
|
||||||
int id;
|
int id;
|
||||||
|
|
||||||
|
if (size < 14)
|
||||||
|
avpriv_request_sample(codec, "wav header size < 14");
|
||||||
|
|
||||||
id = avio_rl16(pb);
|
id = avio_rl16(pb);
|
||||||
codec->codec_type = AVMEDIA_TYPE_AUDIO;
|
codec->codec_type = AVMEDIA_TYPE_AUDIO;
|
||||||
codec->channels = avio_rl16(pb);
|
codec->channels = avio_rl16(pb);
|
||||||
|
Loading…
Reference in New Issue
Block a user