You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-15 14:13:16 +02:00
yop: check return value of avformat_new_stream()
Fixes null pointer dereference, fixes CID703729. Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
@@ -64,6 +64,8 @@ static int yop_read_header(AVFormatContext *s)
|
||||
|
||||
audio_stream = avformat_new_stream(s, NULL);
|
||||
video_stream = avformat_new_stream(s, NULL);
|
||||
if (!audio_stream || !video_stream)
|
||||
return AVERROR(ENOMEM);
|
||||
|
||||
// Extra data that will be passed to the decoder
|
||||
video_stream->codec->extradata_size = 8;
|
||||
|
Reference in New Issue
Block a user