[vlc-devel] [PATCH] Fix bug in taglib txxx handling

Johannes Weißl jargon at molb.org
Wed Feb 16 16:41:56 CET 2011


Hello Jean-Baptiste,

On Wed, Feb 16, 2011 at 01:32:54AM +0100, Jean-Baptiste Kempf wrote:
> > What would be the best way to fix that?
> > 1. Store extra tags all in lowercase / uppercase [vlc_meta_AddExtra()]
> 
> And that will break some tags, no?

I can't think of any. I think ReplayGain is the only "useful" thing the
extra tags are needed for. We would loose all tags differing only in
case, since vlc can only have a single value for a key.

> > 2. Get extra tags case insensitive [vlc_meta_GetExtra()]
> 
> That might break some tags, no?

I didn't think enough about it, it is not possible to get tags case
insensitive, because vlc is storing them in a dictionary (would need to
go through all keys).

> 
> > 3. Just get ReplayGain extra tags case insensitive
> >    [vlc_audio_replay_gain_MergeFromMeta()]
> I would do that, yes.

I attached a patch. It is not (easily) possible to use e.g.
strcasecmp, because extra tags are stored in a dictionary, so this is
the simplest fix. In ParseVorbisComments() [vorbis.c] ReplayGain tags
are directly stored when reading the tags, but this could be removed
now I guess.


Greetings,
Johannes
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Get-ReplayGain-tags-case-insensitively.patch
Type: text/x-diff
Size: 2663 bytes
Desc: not available
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20110216/55ab92c4/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20110216/55ab92c4/attachment.sig>


More information about the vlc-devel mailing list