From 4547fd7b18a8cbf474c1a48fc8b334411ed42b7e Mon Sep 17 00:00:00 2001 From: Michael Eischer Date: Thu, 14 May 2026 10:53:42 +0200 Subject: [PATCH] fuse: tweak comment --- internal/fuse/file.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/internal/fuse/file.go b/internal/fuse/file.go index 986d8428f..6fd042f81 100644 --- a/internal/fuse/file.go +++ b/internal/fuse/file.go @@ -55,7 +55,9 @@ func (f *file) Attr(_ context.Context, a *fuse.Attr) error { a.Size = f.node.Size a.Blocks = (f.node.Size + blockSize - 1) / blockSize a.BlockSize = blockSize - // present a link count > 0 to keep over-eager stat() .st_nlink checks (e.g., from Samba's smbd) happy + // Windows (and other non-POSIX) backups may store a link count of 0. + // FUSE must still report a positive nlink so tools that validate stat() + // (e.g. Samba) accept the file. a.Nlink = max(uint32(1), uint32(f.node.Links)) if !f.root.cfg.OwnerIsRoot {