aboutsummaryrefslogtreecommitdiffstats
path: root/lib/fuse.c
diff options
context:
space:
mode:
authorBernd Schubert <bschubert@ddn.com>2025-05-18 00:24:07 +0200
committerBernd Schubert <bernd@bsbernd.com>2025-05-21 13:44:17 +0200
commit53607e073d075ad1984f7015187d203a3ae83297 (patch)
treea8f6b4e6ae4dc45045e0f200b887e09a27160c7f /lib/fuse.c
parent9925b6e7548d65696f745732617d25481b76acbe (diff)
downloadlibfuse-53607e073d075ad1984f7015187d203a3ae83297.tar.gz
conn->want conversion: Fix fuse_apply_conn_info_opts()
fuse_apply_conn_info_opts() was applying to 'want_ext', which would cause conflicts with 'want' if the application applied its own flags to 'conn->want'. Solution is: - to move fuse_{set,unset,get}_feature_flag and convert_to_conn_want_ext() to fuse_lowlevel.c and to define them as part of the public API, although convert_to_conn_want_ext() should not be used - it is currently needed to be a public function due as it needs to be defined for the tests. Related to https://github.com/libfuse/libfuse/issues/1171 and https://github.com/libfuse/libfuse/pull/1172. Closes: https://github.com/libfuse/libfuse/issues/1171 Signed-off-by: Bernd Schubert <bschubert@ddn.com> (cherry picked from commit baadab0492a495fda98216b351976d2e5d6d0866)
Diffstat (limited to 'lib/fuse.c')
-rw-r--r--lib/fuse.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/lib/fuse.c b/lib/fuse.c
index 4964de2..8591454 100644
--- a/lib/fuse.c
+++ b/lib/fuse.c
@@ -2611,15 +2611,8 @@ void fuse_fs_init(struct fuse_fs *fs, struct fuse_conn_info *conn,
fuse_unset_feature_flag(conn, FUSE_CAP_POSIX_LOCKS);
if (!fs->op.flock)
fuse_unset_feature_flag(conn, FUSE_CAP_FLOCK_LOCKS);
- if (fs->op.init) {
- uint64_t want_ext_default = conn->want_ext;
- uint32_t want_default = fuse_lower_32_bits(conn->want_ext);
-
- conn->want = want_default;
+ if (fs->op.init)
fs->user_data = fs->op.init(conn, cfg);
-
- convert_to_conn_want_ext(conn, want_ext_default, want_default);
- }
}
static int fuse_init_intr_signal(int signum, int *installed);