ignore year=0 and track=0
authorAurelien Jacobs <aurel@gnuage.org>
Tue, 6 Jan 2009 12:56:21 +0000 (12:56 +0000)
committerAurelien Jacobs <aurel@gnuage.org>
Tue, 6 Jan 2009 12:56:21 +0000 (12:56 +0000)
Originally committed as revision 16452 to svn://svn.ffmpeg.org/ffmpeg/trunk

libavformat/metadata.c

index 8a25782..5c7ef06 100644 (file)
@@ -84,7 +84,7 @@ int av_metadata_set(AVMetadata **pm, AVMetadataTag elem)
 #define FILL_METADATA_INT(s, key) {                                           \
     char number[10];                                                          \
     snprintf(number, sizeof(number), "%d", s->key);                           \
-    FILL_METADATA(s, key, number) }
+    if(s->key)  FILL_METADATA(s, key, number) }
 
 void ff_metadata_sync_compat(AVFormatContext *ctx)
 {