Commit 200e60f8 authored by andoma's avatar andoma

make sure the mpeg audio header is valid before passing it to ff_mpegaudio_decode_header()



git-svn-id: file:///var/local/repositories/ffmpeg/trunk@10925 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 0a8ae911
...@@ -435,7 +435,11 @@ static void mp3_parse_vbr_tags(AVFormatContext *s, AVStream *st, offset_t base) ...@@ -435,7 +435,11 @@ static void mp3_parse_vbr_tags(AVFormatContext *s, AVStream *st, offset_t base)
const offset_t xing_offtbl[2][2] = {{32, 17}, {17,9}}; const offset_t xing_offtbl[2][2] = {{32, 17}, {17,9}};
MPADecodeContext c; MPADecodeContext c;
ff_mpegaudio_decode_header(&c, get_be32(&s->pb)); v = get_be32(&s->pb);
if(ff_mpa_check_header(v) < 0)
return;
ff_mpegaudio_decode_header(&c, v);
if(c.layer != 3) if(c.layer != 3)
return; return;
......
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