main: set FUSE_CAP_POSIX_ACL only when supported

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
This commit is contained in:
Giuseppe Scrivano 2021-08-04 18:09:28 +02:00
parent 17605e3633
commit 0a659e75ef
No known key found for this signature in database
GPG Key ID: E4730F97F60286ED

3
main.c
View File

@ -427,6 +427,9 @@ ovl_init (void *userdata, struct fuse_conn_info *conn)
if ((conn->capable & FUSE_CAP_WRITEBACK_CACHE) == 0)
lo->writeback = 0;
if ((conn->capable & FUSE_CAP_POSIX_ACL) == 0)
conn->want |= FUSE_CAP_POSIX_ACL;
conn->want |= FUSE_CAP_DONT_MASK | FUSE_CAP_SPLICE_READ | FUSE_CAP_SPLICE_WRITE | FUSE_CAP_SPLICE_MOVE | FUSE_CAP_POSIX_ACL;
if (lo->writeback)
conn->want |= FUSE_CAP_WRITEBACK_CACHE;