[easytag] Write URL for FLAC and Vorbis to CONTACT field
- From: David King <davidk src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [easytag] Write URL for FLAC and Vorbis to CONTACT field
- Date: Sun, 24 Mar 2013 23:17:23 +0000 (UTC)
commit c0f2836662a3606da8cb550751d7be9abed58ce7
Author: David King <amigadave amigadave com>
Date: Sat Jan 12 15:55:47 2013 +0000
Write URL for FLAC and Vorbis to CONTACT field
EasyTAG incorrectly wrote the URL of fies into the LICENSE field, but
that field is for the license informaton (which may be a URL). CONTACT
is a more appropriate field. Fixes bug 690301.
src/flac_tag.c | 9 ++++++---
src/ogg_tag.c | 6 +++---
2 files changed, 9 insertions(+), 6 deletions(-)
---
diff --git a/src/flac_tag.c b/src/flac_tag.c
index 091f20b..0792cd4 100644
--- a/src/flac_tag.c
+++ b/src/flac_tag.c
@@ -66,6 +66,9 @@
* - GENRE : A short text indication of music genre
* - DATE : Date the track was recorded
* - LOCATION : Location where track was recorded
+ * - CONTACT : Contact information for the creators or distributors of
+ * the track. This could be a URL, an email address, the
+ * physical address of the producing label.
* - COPYRIGHT : Copyright information
* - ISRC : ISRC number for the track; see the ISRC intro page for more information on ISRC numbers.
*
@@ -553,7 +556,7 @@ gboolean Flac_Tag_Read_File_Tag (gchar *filename, File_Tag *FileTag)
* URL *
*******/
field_num = 0;
- while ( (field_num =
FLAC__metadata_object_vorbiscomment_find_entry_from(block,field_num,"LICENSE")) >= 0 )
+ while ((field_num = FLAC__metadata_object_vorbiscomment_find_entry_from (block, field_num,
"CONTACT")) >= 0)
{
/* Extract field value */
field = &vc->comments[field_num++];
@@ -625,7 +628,7 @@ gboolean Flac_Tag_Read_File_Tag (gchar *filename, File_Tag *FileTag)
&& strncasecmp((gchar *)field->entry,"COMPOSER=", MIN(9, field->length)) != 0
&& strncasecmp((gchar *)field->entry,"PERFORMER=", MIN(10, field->length)) != 0
&& strncasecmp((gchar *)field->entry,"COPYRIGHT=", MIN(10, field->length)) != 0
- && strncasecmp((gchar *)field->entry,"LICENSE=", MIN(8, field->length)) != 0
+ && strncasecmp((gchar *)field->entry,"CONTACT=", MIN(8, field->length)) != 0
&& strncasecmp((gchar *)field->entry,"ENCODED-BY=", MIN(11, field->length)) != 0 )
{
//g_print("custom %*s\n", field->length, field->entry);
@@ -991,7 +994,7 @@ gboolean Flac_Tag_Write_File_Tag (ET_File *ETFile)
/*******
* URL *
*******/
- Flac_Set_Tag(vc_block,"LICENSE=",FileTag->url,FALSE);
+ Flac_Set_Tag (vc_block, "CONTACT=", FileTag->url, FALSE);
/**************
* Encoded by *
diff --git a/src/ogg_tag.c b/src/ogg_tag.c
index 1f8b959..dc71a31 100644
--- a/src/ogg_tag.c
+++ b/src/ogg_tag.c
@@ -463,7 +463,7 @@ gboolean Ogg_Tag_Read_File_Tag (gchar *filename, File_Tag *FileTag)
* URL *
*******/
field_num = 0;
- while ( (string = vorbis_comment_query(vc,"LICENSE",field_num++)) != NULL )
+ while ((string = vorbis_comment_query (vc, "CONTACT", field_num++)) != NULL)
{
string = Try_To_Validate_Utf8_String(string);
@@ -562,7 +562,7 @@ gboolean Ogg_Tag_Read_File_Tag (gchar *filename, File_Tag *FileTag)
&& strncasecmp(vc->user_comments[i],"COMPOSER=", 9) != 0
&& strncasecmp(vc->user_comments[i],"PERFORMER=", 10) != 0
&& strncasecmp(vc->user_comments[i],"COPYRIGHT=", 10) != 0
- && strncasecmp(vc->user_comments[i],"LICENSE=", 8) != 0
+ && strncasecmp(vc->user_comments[i],"CONTACT=", 8) != 0
&& strncasecmp(vc->user_comments[i],"ENCODED-BY=", 11) != 0
&& strncasecmp(vc->user_comments[i],"COVERART=", 9) != 0
&& strncasecmp(vc->user_comments[i],"COVERARTTYPE=", 13) != 0
@@ -765,7 +765,7 @@ gboolean Ogg_Tag_Write_File_Tag (ET_File *ETFile)
/*******
* URL *
*******/
- Ogg_Set_Tag(vc,"LICENSE=",FileTag->url,FALSE);
+ Ogg_Set_Tag (vc, "CONTACT=", FileTag->url, FALSE);
/**************
* Encoded by *
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]