tools/ismindex: use av_mallocz_array()
authorMichael Niedermayer <michaelni@gmx.at>
Mon, 5 May 2014 16:40:55 +0000 (18:40 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Mon, 5 May 2014 16:47:24 +0000 (18:47 +0200)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
tools/ismindex.c

index 4dc3e12..759bc0f 100644 (file)
@@ -163,7 +163,7 @@ static int read_tfra(struct Tracks *tracks, int start_index, AVIOContext *f)
     }
     fieldlength = avio_rb32(f);
     track->chunks  = avio_rb32(f);
-    track->offsets = av_mallocz(sizeof(*track->offsets) * track->chunks);
+    track->offsets = av_mallocz_array(track->chunks, sizeof(*track->offsets));
     if (!track->offsets) {
         ret = AVERROR(ENOMEM);
         goto fail;