[FFmpeg-cvslog] avformat/xmv: use av_malloc_array()

Michael Niedermayer git at videolan.org
Tue Apr 15 13:57:02 CEST 2014


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Tue Apr 15 13:45:26 2014 +0200| [eead2cddb773bbb26e5ee66b6438d0a2190c4710] | committer: Michael Niedermayer

avformat/xmv: use av_malloc_array()

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=eead2cddb773bbb26e5ee66b6438d0a2190c4710
---

 libavformat/xmv.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/xmv.c b/libavformat/xmv.c
index 705a302..6eac4d2 100644
--- a/libavformat/xmv.c
+++ b/libavformat/xmv.c
@@ -182,7 +182,7 @@ static int xmv_read_header(AVFormatContext *s)
 
     avio_skip(pb, 2); /* Unknown (padding?) */
 
-    xmv->audio = av_malloc(xmv->audio_track_count * sizeof(XMVAudioPacket));
+    xmv->audio = av_malloc_array(xmv->audio_track_count, sizeof(XMVAudioPacket));
     if (!xmv->audio) {
         ret = AVERROR(ENOMEM);
         goto fail;



More information about the ffmpeg-cvslog mailing list