From e885abe1a3f6a0a6a795f7f75f601c80566a3de2 Mon Sep 17 00:00:00 2001 From: Joe Lim <50560759+joelim-work@users.noreply.github.com> Date: Sat, 10 Jun 2023 18:50:02 +1000 Subject: [PATCH] Fix formatting of nlink on other platforms (#1295) --- os.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/os.go b/os.go index d26b9f1f..46ee6940 100644 --- a/os.go +++ b/os.go @@ -10,7 +10,6 @@ import ( "os/user" "path/filepath" "runtime" - "strconv" "strings" "syscall" @@ -210,7 +209,7 @@ func groupName(f os.FileInfo) string { func linkCount(f os.FileInfo) string { if stat, ok := f.Sys().(*syscall.Stat_t); ok { - return strconv.FormatUint(stat.Nlink, 10) + return fmt.Sprint(stat.Nlink) } return "" }