From 2e1aec0fcfd412cff22cc4fc996973e403589ad8 Mon Sep 17 00:00:00 2001 From: Jeff Halter <868228+jhalter@users.noreply.github.com> Date: Thu, 4 Apr 2024 15:37:28 -0700 Subject: Add support for Mac Roman character encoding. https://en.wikipedia.org/wiki/Mac_OS_Roman --- hotline/files.go | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'hotline/files.go') diff --git a/hotline/files.go b/hotline/files.go index 63fa482..0746b1f 100644 --- a/hotline/files.go +++ b/hotline/files.go @@ -118,6 +118,10 @@ func getFileNameList(path string, ignoreList []string) (fields []Field, err erro } strippedName := strings.ReplaceAll(file.Name(), ".incomplete", "") + strippedName, err = txtEncoder.String(strippedName) + if err != nil { + return nil, err + } nameSize := make([]byte, 2) binary.BigEndian.PutUint16(nameSize, uint16(len(strippedName))) -- cgit