diff options
author | Nikolaus Rath <Nikolaus@rath.org> | 2017-08-22 17:05:26 +0200 |
---|---|---|
committer | Nikolaus Rath <Nikolaus@rath.org> | 2017-08-22 17:05:26 +0200 |
commit | 84499b2eefb0c8496b9eccb8b2c0f5928fb68ce6 (patch) | |
tree | c4c878651d409aef5889c496ecddb6bf0ceab521 /lib | |
parent | f88a285cf28b41064f0ed4c5a7e360c97059f942 (diff) | |
download | libfuse-84499b2eefb0c8496b9eccb8b2c0f5928fb68ce6.tar.gz |
Document and unify error codes of fuse_lowlevel_notify_*
Diffstat (limited to 'lib')
-rw-r--r-- | lib/fuse_lowlevel.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/lib/fuse_lowlevel.c b/lib/fuse_lowlevel.c index ff7de82..3d78d9e 100644 --- a/lib/fuse_lowlevel.c +++ b/lib/fuse_lowlevel.c @@ -2123,6 +2123,9 @@ int fuse_lowlevel_notify_inval_inode(struct fuse_session *se, fuse_ino_t ino, if (!se) return -EINVAL; + if (se->conn.proto_major < 6 || se->conn.proto_minor < 12) + return -ENOSYS; + outarg.ino = ino; outarg.off = off; outarg.len = len; @@ -2141,6 +2144,9 @@ int fuse_lowlevel_notify_inval_entry(struct fuse_session *se, fuse_ino_t parent, if (!se) return -EINVAL; + + if (se->conn.proto_major < 6 || se->conn.proto_minor < 12) + return -ENOSYS; outarg.parent = parent; outarg.namelen = namelen; @@ -2164,7 +2170,7 @@ int fuse_lowlevel_notify_delete(struct fuse_session *se, if (!se) return -EINVAL; - if (se->conn.proto_minor < 18) + if (se->conn.proto_major < 6 || se->conn.proto_minor < 18) return -ENOSYS; outarg.parent = parent; @@ -2193,7 +2199,7 @@ int fuse_lowlevel_notify_store(struct fuse_session *se, fuse_ino_t ino, if (!se) return -EINVAL; - if (se->conn.proto_minor < 15) + if (se->conn.proto_major < 6 || se->conn.proto_minor < 15) return -ENOSYS; out.unique = 0; @@ -2271,7 +2277,7 @@ int fuse_lowlevel_notify_retrieve(struct fuse_session *se, fuse_ino_t ino, if (!se) return -EINVAL; - if (se->conn.proto_minor < 15) + if (se->conn.proto_major < 6 || se->conn.proto_minor < 15) return -ENOSYS; rreq = malloc(sizeof(*rreq)); |