avformat/wtvenc: Use av_realloc_array()

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2015-04-11 13:50:07 +02:00
parent e0d8ff5ef1
commit e33355213d

View File

@ -112,7 +112,7 @@ typedef struct {
static void add_serial_pair(WtvSyncEntry ** list, int * count, int64_t serial, int64_t value)
{
int new_count = *count + 1;
WtvSyncEntry *new_list = av_realloc(*list, new_count * sizeof(WtvSyncEntry));
WtvSyncEntry *new_list = av_realloc_array(*list, new_count, sizeof(WtvSyncEntry));
if (!new_list)
return;
new_list[*count] = (WtvSyncEntry){serial, value};