aboutsummaryrefslogtreecommitdiffstats
path: root/lib/mount_bsd.c
diff options
context:
space:
mode:
authorVassili Tchersky <vt+git@vbcy.org>2025-02-17 08:54:10 +0100
committerBernd Schubert <bernd@bsbernd.com>2025-02-18 22:32:49 +0100
commit8af70b496cac0f69a4b2835bc5388a8e327725a8 (patch)
tree4f0489c82c8bbee6a94394f41c166db012d07f0f /lib/mount_bsd.c
parent981c97aed4813fd3ed0f0ceb7241c1f26e32b1b6 (diff)
downloadlibfuse-8af70b496cac0f69a4b2835bc5388a8e327725a8.tar.gz
mount_bsd: Proper exit calls
Use _exit() instead of exit() inside children Signed-off-by: Vassili Tchersky <vt+git@vbcy.org>
Diffstat (limited to 'lib/mount_bsd.c')
-rw-r--r--lib/mount_bsd.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/mount_bsd.c b/lib/mount_bsd.c
index 789f61b..ba17240 100644
--- a/lib/mount_bsd.c
+++ b/lib/mount_bsd.c
@@ -189,7 +189,7 @@ mount:
const char *argv[32];
int a = 0;
int ret = -1;
-
+
if (! fdnam)
{
ret = asprintf(&fdnam, "%ld", fd);
@@ -197,7 +197,7 @@ mount:
{
perror("fuse: failed to assemble mount arguments");
close(fd);
- exit(1);
+ _exit(EXIT_FAILURE);
}
}
@@ -212,10 +212,10 @@ mount:
execvp(mountprog, (char **) argv);
perror("fuse: failed to exec mount program");
free(fdnam);
- exit(1);
+ _exit(EXIT_FAILURE);
}
- exit(0);
+ _exit(EXIT_SUCCESS);
}
if (waitpid(cpid, &status, 0) == -1 || WEXITSTATUS(status) != 0) {