diff options
author | Vassili Tchersky <vt+git@vbcy.org> | 2025-02-17 08:53:03 +0100 |
---|---|---|
committer | Bernd Schubert <bernd@bsbernd.com> | 2025-02-18 22:32:49 +0100 |
commit | 981c97aed4813fd3ed0f0ceb7241c1f26e32b1b6 (patch) | |
tree | 30bb38be6ec84897889f3aabd54211196a0dc342 /lib | |
parent | fa1c84d0e0a60db855aa42aab4363624c6796e70 (diff) | |
download | libfuse-981c97aed4813fd3ed0f0ceb7241c1f26e32b1b6.tar.gz |
FreeBSD: Remove useless options
These options never had any effect.
See https://svnweb.freebsd.org/base?view=revision&revision=347544
Signed-off-by: Vassili Tchersky <vt+git@vbcy.org>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/mount_bsd.c | 37 |
1 files changed, 6 insertions, 31 deletions
diff --git a/lib/mount_bsd.c b/lib/mount_bsd.c index 85332d3..789f61b 100644 --- a/lib/mount_bsd.c +++ b/lib/mount_bsd.c @@ -19,7 +19,6 @@ #include <sys/stat.h> #include <sys/wait.h> -#include <sys/sysctl.h> #include <sys/user.h> #include <stdio.h> #include <stdlib.h> @@ -86,7 +85,6 @@ static const struct fuse_opt fuse_mount_opts[] = { FUSE_DUAL_OPT_KEY("private", KEY_KERN), FUSE_DUAL_OPT_KEY("neglect_shares", KEY_KERN), FUSE_DUAL_OPT_KEY("push_symlinks_in", KEY_KERN), - FUSE_OPT_KEY("nosync_unmount", KEY_KERN), #if __FreeBSD_version >= 1200519 FUSE_DUAL_OPT_KEY("intr", KEY_KERN), #endif @@ -134,21 +132,6 @@ void fuse_kern_unmount(const char *mountpoint, int fd) unmount(mountpoint, MNT_FORCE); } -/* Check if kernel is doing init in background */ -static int init_backgrounded(void) -{ - unsigned ibg; - size_t len; - - len = sizeof(ibg); - - if (sysctlbyname("vfs.fuse.init_backgrounded", &ibg, &len, NULL, 0)) - return 0; - - return ibg; -} - - static int fuse_mount_core(const char *mountpoint, const char *opts) { const char *mountprog = FUSERMOUNT_PROG; @@ -194,20 +177,12 @@ mount: } if (pid == 0) { - if (! init_backgrounded()) { - /* - * If init is not backgrounded, we have to - * call the mount util backgrounded, to avoid - * deadlock. - */ - - pid = fork(); - - if (pid == -1) { - perror("fuse: fork() failed"); - close(fd); - exit(1); - } + pid = fork(); + + if (pid == -1) { + perror("fuse: fork() failed"); + close(fd); + _exit(EXIT_FAILURE); } if (pid == 0) { |