[FFmpeg-cvslog] r18145 - trunk/libavformat/mp3.c
aurel
subversion
Sun Mar 22 17:10:37 CET 2009
Author: aurel
Date: Sun Mar 22 17:10:37 2009
New Revision: 18145
Log:
handle id3v2 'genre' tag formated as '%d'
Modified:
trunk/libavformat/mp3.c
Modified: trunk/libavformat/mp3.c
==============================================================================
--- trunk/libavformat/mp3.c Sun Mar 22 14:05:13 2009 (r18144)
+++ trunk/libavformat/mp3.c Sun Mar 22 17:10:37 2009 (r18145)
@@ -198,7 +198,8 @@ static void id3v2_read_ttag(AVFormatCont
}
if (!strcmp(key, "genre")
- && sscanf(dst, "(%d)", &genre) == 1 && genre <= ID3v1_GENRE_MAX)
+ && (sscanf(dst, "(%d)", &genre) == 1 || sscanf(dst, "%d", &genre) == 1)
+ && genre <= ID3v1_GENRE_MAX)
av_strlcpy(dst, id3v1_genre_str[genre], sizeof(dst));
if (*dst)
More information about the ffmpeg-cvslog
mailing list