Commit 1f196051 authored by Michael Niedermayer's avatar Michael Niedermayer

lxfdec: fix "no audio stream" check. avoid null ptrs deref

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 334a0d15
......@@ -165,7 +165,7 @@ static int get_packet_header(AVFormatContext *s)
break;
case 1:
//audio
if (!(st = s->streams[1])) {
if (!s->streams || !(st = s->streams[1])) {
av_log(s, AV_LOG_INFO, "got audio packet, but no audio stream present\n");
break;
}
......
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