[MPlayer-cvslog] r21908 - trunk/libmpdemux/demux_gif.c

reimar subversion at mplayerhq.hu
Sat Jan 13 13:05:18 CET 2007


Author: reimar
Date: Sat Jan 13 13:05:18 2007
New Revision: 21908

Modified:
   trunk/libmpdemux/demux_gif.c

Log:
memset + malloc -> calloc


Modified: trunk/libmpdemux/demux_gif.c
==============================================================================
--- trunk/libmpdemux/demux_gif.c	(original)
+++ trunk/libmpdemux/demux_gif.c	Sat Jan 13 13:05:18 2007
@@ -107,8 +107,7 @@
 
   len = gif->Image.Width * gif->Image.Height;
   dp = new_demux_packet(priv->w * priv->h);
-  buf = malloc(len);
-  memset(buf, 0, len);
+  buf = calloc(gif->Image.Width, gif->Image.Height);
   memset(dp->buffer, 0, priv->w * priv->h);
   
   if (DGifGetLine(gif, buf, len) == GIF_ERROR) {



More information about the MPlayer-cvslog mailing list