[FFmpeg-cvslog] avcodec/ass: Use av_realloc_array()

Michael Niedermayer git at videolan.org
Fri Jan 9 20:45:45 CET 2015


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Fri Jan  9 18:57:37 2015 +0100| [727cb2bda9df0f5f66d19846d529da73751737c3] | committer: Michael Niedermayer

avcodec/ass: Use av_realloc_array()

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

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

 libavcodec/ass.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/ass.c b/libavcodec/ass.c
index 3a37cee..ea247f8 100644
--- a/libavcodec/ass.c
+++ b/libavcodec/ass.c
@@ -154,7 +154,7 @@ int ff_ass_add_rect(AVSubtitle *sub, const char *dialog,
     if (!av_bprint_is_complete(&buf))
         goto errnomem;
 
-    rects = av_realloc(sub->rects, (sub->num_rects+1) * sizeof(*sub->rects));
+    rects = av_realloc_array(sub->rects, (sub->num_rects+1), sizeof(*sub->rects));
     if (!rects)
         goto errnomem;
     sub->rects = rects;



More information about the ffmpeg-cvslog mailing list