mirror of https://git.ffmpeg.org/ffmpeg.git
avformat/matroskadec: use av_realloc_array()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
b5b34c1983
commit
e529082369
|
@ -950,7 +950,7 @@ static int ebml_parse_elem(MatroskaDemuxContext *matroska,
|
|||
data = (char *)data + syntax->data_offset;
|
||||
if (syntax->list_elem_size) {
|
||||
EbmlList *list = data;
|
||||
newelem = av_realloc(list->elem, (list->nb_elem+1)*syntax->list_elem_size);
|
||||
newelem = av_realloc_array(list->elem, list->nb_elem+1, syntax->list_elem_size);
|
||||
if (!newelem)
|
||||
return AVERROR(ENOMEM);
|
||||
list->elem = newelem;
|
||||
|
|
Loading…
Reference in New Issue