[FFmpeg-cvslog] movenc: Replace av_realloc by av_realloc_f when relevant.

Nicolas George git at videolan.org
Sat Oct 1 21:38:55 CEST 2011


ffmpeg | branch: release/0.8 | Nicolas George <nicolas.george at normalesup.org> | Wed Sep 28 17:16:11 2011 +0200| [17b6abab50a42f1b81b8ae2207f86f2c76564380] | committer: Michael Niedermayer

movenc: Replace av_realloc by av_realloc_f when relevant.

Signed-off-by: Nicolas George <nicolas.george at normalesup.org>
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
(cherry picked from commit 194c2432eecd97c36914956f3bf7781ac4fc6f3d)

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

 libavformat/movenc.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/libavformat/movenc.c b/libavformat/movenc.c
index 463dd5b..076f2e3 100644
--- a/libavformat/movenc.c
+++ b/libavformat/movenc.c
@@ -2058,7 +2058,7 @@ int ff_mov_write_packet(AVFormatContext *s, AVPacket *pkt)
     }
 
     if (!(trk->entry % MOV_INDEX_CLUSTER_SIZE)) {
-        trk->cluster = av_realloc(trk->cluster, (trk->entry + MOV_INDEX_CLUSTER_SIZE) * sizeof(*trk->cluster));
+        trk->cluster = av_realloc_f(trk->cluster, sizeof(*trk->cluster), (trk->entry + MOV_INDEX_CLUSTER_SIZE));
         if (!trk->cluster)
             return -1;
     }



More information about the ffmpeg-cvslog mailing list