In OggFile.GetTag() was added another layer of indexing, this time we are looking for a capitalised tag name (e.g. Artist). Why there's no consistency in OGG vorbis tags..? *Sigh*
This commit is contained in:
parent
0d8032da46
commit
eb65071b51
@ -74,9 +74,11 @@ func (of *OggFile) GetTag(tag string) string {
|
||||
tagIdx := bytes.Index(of.bufHead, append([]byte{0, 0, 0}, (tag+"=")...))
|
||||
if tagIdx == -1 {
|
||||
if tagIdx = bytes.Index(of.bufHead, append([]byte{0, 0, 0}, (strings.ToUpper(tag)+"=")...)); tagIdx == -1 {
|
||||
if tagIdx = bytes.Index(of.bufHead, append([]byte{0, 0, 0}, (strings.Title(tag)+"=")...)); tagIdx == -1 {
|
||||
return ""
|
||||
}
|
||||
}
|
||||
}
|
||||
tagIdx += 3
|
||||
tagNameLen := len(tag) + 1
|
||||
valStart := tagIdx + tagNameLen
|
||||
|
Loading…
Reference in New Issue
Block a user