diff --git a/fs/fuse/backing.c b/fs/fuse/backing.c index f4f529ff8580..3b2b2a470ba4 100644 --- a/fs/fuse/backing.c +++ b/fs/fuse/backing.c @@ -353,7 +353,9 @@ int fuse_release_initialize(struct fuse_bpf_args *fa, struct fuse_release_in *fr struct inode *inode, struct fuse_file *ff) { /* Always put backing file whatever bpf/userspace says */ - fput(ff->backing_file); + if (ff->backing_file) { + fput(ff->backing_file); + } *fri = (struct fuse_release_in) { .fh = ff->fh,