Bug 3392 - multiple genre tags for ID3v2.4 (null separated) not supported
: multiple genre tags for ID3v2.4 (null separated) not supported
Status: CLOSED FIXED
Product: Logitech Media Server
Classification: Unclassified
Component: Tagging
: 6.2.2
: PC Windows XP
: P3 minor (vote)
: ---
Assigned To: Dan Sully
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-05-04 13:22 UTC by Hanno Stock
Modified: 2008-09-15 14:38 UTC (History)
0 users

See Also:
Category: ---


Attachments
Sample file with ID3v2.4 null separated genre list (2.27 MB, application/octet-stream)
2006-05-04 13:31 UTC, Hanno Stock
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Hanno Stock 2006-05-04 13:22:30 UTC
I have some files with multiple genres in ID3v2.4 tags. The genres are separated by \000 characters. (I have verified that with a hex editor)
Slimserver does only recognize the first genre. I know this is supposed to be fixed (bug 217), but I cannot get it to work.
Files have been tagged with MP3tag v2.35o (not 2.35 - that created multiple TCON fields.)
Comment 1 Hanno Stock 2006-05-04 13:31:42 UTC
Created attachment 1227 [details]
Sample file with ID3v2.4 null separated genre list

This file has multiple genres, but only the first is recognized by slimserver
Comment 2 Dan Sully 2006-05-04 14:56:25 UTC
This format isn't valid according to the ID3 spec.

Sounds like it was a bug in your tagging program.
Comment 3 Hanno Stock 2006-05-05 10:34:02 UTC
From http://www.id3.org/id3v2.4.0-frames.txt I read:

"All text
   information frames supports multiple strings, stored as a null
   separated list, where null is reperesented by the termination code
   for the charater encoding." (Section 4.2)

As I understand it, this is the format used in the sample file.

Also I don't know whether there should be a single or double null-character
at the end of the list.

I would be willing to look into the code myself, if we can clarify the
issue.
Comment 4 Dan Sully 2006-05-05 10:41:43 UTC
Aha - thanks. I was looking specifically at the TCON section.

Fixed in change 7311
Comment 5 Hanno Stock 2006-05-05 11:33:25 UTC
Just had a look at the change.
Does Slimserver support UTF-16-tags? For UTF-16, it is two \0 instead of one.
Comment 6 Dan Sully 2006-05-05 11:36:41 UTC
Earlier in the processing Unicode handling is done. Additionally, multiple nulls are turned into 1 null in the TCON loop.
Comment 7 Hanno Stock 2006-05-05 12:19:52 UTC
Ah, didn't see that - ok.

However the fix did not work for me. I changed it the following way
- now it works. (I thin \w doesn't match space and AFAIK space is allowed
for genres, i.e.: "Progressive Rock")

Index: Info.pm
===================================================================
--- Info.pm	(revision 7415)
+++ Info.pm	(working copy)
@@ -948,10 +948,10 @@
 
 						$data = \@genres;
 
-					} elsif ($data =~ /^(\w+)\000/) {
+					} elsif ($data =~ /^[^\000]+\000/) {
 
 						# name genres separated by nulls.
-						$data = [ split /\0/, $data ];
+						$data = [ split /\000/, $data ];
 					}
 
 					# Text based genres will fall through.
Comment 8 Chris Owens 2006-06-27 14:22:06 UTC
This bug fix is now part of a released version, and so has been marked closed. If you are still experiencing this problem, please reopen the bug.