提交 337f7486 编写于 作者: M Michael Niedermayer

avformat/mpegtsenc: use av_malloc_array()

Signed-off-by: NMichael Niedermayer <michaelni@gmx.at>
上级 083b6e73
......@@ -628,7 +628,7 @@ static int mpegts_write_header(AVFormatContext *s)
ts->sdt.write_packet = section_write_packet;
ts->sdt.opaque = s;
pids = av_malloc(s->nb_streams * sizeof(*pids));
pids = av_malloc_array(s->nb_streams, sizeof(*pids));
if (!pids)
return AVERROR(ENOMEM);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册