提交 2922cbdb 编写于 作者: B Baptiste Coudurier

cannot free AVStream like this, and return ENOMEM

Originally committed as revision 12529 to svn://svn.ffmpeg.org/ffmpeg/trunk
上级 e3c4740f
......@@ -1204,10 +1204,7 @@ static int mov_read_trak(MOVContext *c, ByteIOContext *pb, MOV_atom_t atom)
st = av_new_stream(c->fc, c->fc->nb_streams);
if (!st) return -2;
sc = av_mallocz(sizeof(MOVStreamContext));
if (!sc) {
av_free(st);
return -1;
}
if (!sc) return AVERROR(ENOMEM);
st->priv_data = sc;
st->codec->codec_type = CODEC_TYPE_DATA;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册