OSDN Git Service

Fix a __warn_memset_zero_len gcc-4.4 warning.
authorAlex Converse <alex.converse@gmail.com>
Thu, 12 Nov 2009 01:44:38 +0000 (01:44 +0000)
committerAlex Converse <alex.converse@gmail.com>
Thu, 12 Nov 2009 01:44:38 +0000 (01:44 +0000)
Originally committed as revision 20521 to svn://svn.ffmpeg.org/ffmpeg/trunk

libavcodec/alsdec.c

index 47b708f..bd9a17f 100644 (file)
@@ -670,6 +670,7 @@ static void zero_remaining(unsigned int b, unsigned int b_max,
     while (b < b_max)
         count += div_blocks[b];
 
+    if (count)
     memset(buf, 0, sizeof(*buf) * count);
 }