git: fuse: treat a zero file handle as a valid handle

Aaron LI aly at crater.dragonflybsd.org
Wed Nov 18 05:12:57 PST 2026


commit 84e673facfd446061cf4144507fd50fce9ed4cc5
Author: David Bidner <david at crap.solutions>
Date:   Sun Nov 1 08:32:41 2026 +0100

    fuse: treat a zero file handle as a valid handle
    
    ntfs-3g returns file handle 0 for regular files.  The driver used
    fh == 0 as its "no handle" state, so it reopened the file on every
    open and skipped FUSE_RELEASE and FUSE_FSYNC.  The userspace daemon
    then still considered the file open and renamed unlinked files to
    .fuse_hidden*.
    
    Add an explicit fh_valid flag to struct fuse_node and use it instead
    of the fh value.
    
    Bug: https://bugs.dragonflybsd.org/issues/3459

Summary of changes:
 sys/vfs/fuse/fuse.h       |  1 +
 sys/vfs/fuse/fuse_vnops.c | 10 ++++++----
 2 files changed, 7 insertions(+), 4 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/84e673facfd446061cf4144507fd50fce9ed4cc5


-- 
DragonFly BSD source repository


More information about the Commits mailing list