aboutsummaryrefslogtreecommitdiffstats
path: root/example
diff options
context:
space:
mode:
authorNikolaus Rath <Nikolaus@rath.org>2022-03-14 09:48:43 +0000
committerGitHub <noreply@github.com>2022-03-14 09:48:43 +0000
commit2b7a6f065b6e30723d6cc8668cff198dbb62b914 (patch)
tree6420fbb2ddc1c8f04f6c4a05633401d3ceca68e1 /example
parent3c2ba7aa2500618b7b11255ef3f699d6615ad5a2 (diff)
parent66b04453b7a5d7aefa0a55e9101afe0347215128 (diff)
downloadlibfuse-2b7a6f065b6e30723d6cc8668cff198dbb62b914.tar.gz
Merge pull request #635 from amir73il/fopen_noflush
Add support for FOPEN_NOFLUSH flag
Diffstat (limited to 'example')
-rw-r--r--example/passthrough_hp.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/example/passthrough_hp.cc b/example/passthrough_hp.cc
index 872fc73..e15f893 100644
--- a/example/passthrough_hp.cc
+++ b/example/passthrough_hp.cc
@@ -856,6 +856,7 @@ static void sfs_open(fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) {
lock_guard<mutex> g {inode.m};
inode.nopen++;
fi->keep_cache = (fs.timeout != 0);
+ fi->noflush = (fs.timeout == 0 && (fi->flags & O_ACCMODE) == O_RDONLY);
fi->fh = fd;
fuse_reply_open(req, fi);
}