Use dedicated readStringTrimNULL function in id3v1

This commit is contained in:
jo
2018-09-03 15:15:19 +02:00
parent 5cdccc9693
commit bcc288a50a
2 changed files with 11 additions and 3 deletions
+3 -3
View File
@@ -54,17 +54,17 @@ func ReadID3v1Tags(r io.ReadSeeker) (Metadata, error) {
return nil, ErrNotID3v1
}
title, err := readString(r, 30)
title, err := readStringTrimNULL(r, 30)
if err != nil {
return nil, err
}
artist, err := readString(r, 30)
artist, err := readStringTrimNULL(r, 30)
if err != nil {
return nil, err
}
album, err := readString(r, 30)
album, err := readStringTrimNULL(r, 30)
if err != nil {
return nil, err
}