Commit ccf9211e authored by Piotr Bandurski's avatar Piotr Bandurski Committed by Michael Niedermayer

avformat/utils: avformat_find_stream_info fix a crash in case of oom

fixes ticket #2767
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 0574fe76
......@@ -2783,6 +2783,8 @@ int avformat_find_stream_info(AVFormatContext *ic, AVDictionary **options)
} else {
pkt = add_to_pktbuf(&ic->packet_buffer, &pkt1,
&ic->packet_buffer_end);
if (!pkt)
goto find_stream_info_err;
if ((ret = av_dup_packet(pkt)) < 0)
goto find_stream_info_err;
}
......
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