[FFmpeg-cvslog] r16956 - trunk/libavformat/mp3.c

aurel subversion
Mon Feb 2 23:17:15 CET 2009


Author: aurel
Date: Mon Feb  2 23:17:14 2009
New Revision: 16956

Log:
simplify usage of dstlen as it is not a parameter anymore

Modified:
   trunk/libavformat/mp3.c

Modified: trunk/libavformat/mp3.c
==============================================================================
--- trunk/libavformat/mp3.c	Mon Feb  2 23:14:28 2009	(r16955)
+++ trunk/libavformat/mp3.c	Mon Feb  2 23:17:14 2009	(r16956)
@@ -170,16 +170,14 @@ static unsigned int id3v2_get_size(ByteI
 static void id3v2_read_ttag(AVFormatContext *s, int taglen, const char *key)
 {
     char *q, dst[512];
-    int len, dstlen = sizeof(dst);
+    int len, dstlen = sizeof(dst) - 1;
     unsigned genre;
 
-    if(dstlen > 0)
         dst[0]= 0;
     if(taglen < 1)
         return;
 
     taglen--; /* account for encoding type byte */
-    dstlen--; /* Leave space for zero terminator */
 
     switch(get_byte(s->pb)) { /* encoding type */
 




More information about the ffmpeg-cvslog mailing list