Improve getattr() description
authorNikolaus Rath <Nikolaus@rath.org>
Tue, 15 Nov 2016 00:13:11 +0000 (16:13 -0800)
committerNikolaus Rath <Nikolaus@rath.org>
Tue, 15 Nov 2016 00:13:11 +0000 (16:13 -0800)
When writeback caching is enabled, the st_size value reported
by the filesystem may be ignored.

include/fuse_lowlevel.h

index 0ae773442c43be83afda5b53c73628f20602f3e9..7b007e7b05be519ff2ffd84989a7007f0bbf7d7f 100644 (file)
@@ -248,7 +248,15 @@ struct fuse_lowlevel_ops {
        void (*forget) (fuse_req_t req, fuse_ino_t ino, uint64_t nlookup);
 
        /**
-        * Get file attributes
+        * Get file attributes.
+        *
+        * If writeback caching is enabled, the kernel may have a
+        * better idea of a file's length than the FUSE file system
+        * (eg if there has been a write that extended the file size,
+        * but that has not yet been passed to the filesystem.n
+        *
+        * In this case, the st_size value provided by the file system
+        * will be ignored.
         *
         * Valid replies:
         *   fuse_reply_attr