From f4ddc56a4c796eabed3c9e2af17dbd41a320a17e Mon Sep 17 00:00:00 2001 From: Markus Krogh Date: Sun, 1 Apr 2018 23:26:56 +0200 Subject: [PATCH] id3v2 : fix triple null termination utf-16 little endian. (#36) * Fix triple null termination utf-16 little endian. When fixing result[1] result[0] should be fixed as well. * result[0] should be fixed before fixing result[1] --- id3v2frames.go | 1 + 1 file changed, 1 insertion(+) diff --git a/id3v2frames.go b/id3v2frames.go index e6a06ed..713ae9d 100644 --- a/id3v2frames.go +++ b/id3v2frames.go @@ -370,6 +370,7 @@ func dataSplit(b []byte, enc byte) ([][]byte, error) { if result[1][0] == 0 { // there was a double (or triple) 0 and we cut too early + result[0] = append(result[0], result[1][0]) result[1] = result[1][1:] } return result, nil