提交 a8a90906 编写于 作者: L Luca Barbato

mov: Correctly allocate ctts_data

It can be reallocated.

CC: libav-stable@libav.org
上级 f261a55d
......@@ -2035,7 +2035,7 @@ static int mov_read_ctts(MOVContext *c, AVIOContext *pb, MOVAtom atom)
return 0;
if (entries >= UINT_MAX / sizeof(*sc->ctts_data))
return AVERROR_INVALIDDATA;
sc->ctts_data = av_malloc(entries * sizeof(*sc->ctts_data));
sc->ctts_data = av_realloc(NULL, entries * sizeof(*sc->ctts_data));
if (!sc->ctts_data)
return AVERROR(ENOMEM);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册