Commit 722b79b9 authored by bcoudurier's avatar bcoudurier

check av_new_stream return value, patch by Kent Mein, mein at cs dot umn dot edu

git-svn-id: file:///var/local/repositories/ffmpeg/trunk@19701 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 916aa6c3
......@@ -87,6 +87,8 @@ static int r3d_read_red1(AVFormatContext *s)
dprintf(s, "audio channels %d\n", tmp);
if (tmp > 0) {
AVStream *ast = av_new_stream(s, 1);
if (!ast)
return AVERROR(ENOMEM);
ast->codec->codec_type = CODEC_TYPE_AUDIO;
ast->codec->codec_id = CODEC_ID_PCM_S32BE;
ast->codec->channels = tmp;
......
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