aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorMiklos Szeredi <miklos@szeredi.hu>2005-11-10 09:54:41 +0000
committerMiklos Szeredi <miklos@szeredi.hu>2005-11-10 09:54:41 +0000
commitbcc5385cc146c45bfe08e8351e3dcdd1d6354fee (patch)
tree6c9660f734255bb655c97bb81441fdfcccb71c5b /lib
parent4ec0681e0576c6892f7d919d14bf6188c728b9f8 (diff)
downloadlibfuse-bcc5385cc146c45bfe08e8351e3dcdd1d6354fee.tar.gz
fix
Diffstat (limited to 'lib')
-rw-r--r--lib/helper.c8
-rw-r--r--lib/mount.c5
2 files changed, 7 insertions, 6 deletions
diff --git a/lib/helper.c b/lib/helper.c
index ae43c87..89cd7a8 100644
--- a/lib/helper.c
+++ b/lib/helper.c
@@ -274,12 +274,6 @@ static int fuse_parse_cmdline(int argc, const char *argv[], char **kernel_opts,
goto err;
}
}
-
- if (*mountpoint == NULL) {
- fprintf(stderr, "missing mountpoint\n");
- fprintf(stderr, "see `%s -h' for usage\n", argv[0]);
- goto err;
- }
return 0;
err:
@@ -371,6 +365,8 @@ struct fuse *fuse_setup_compat2(int argc, char *argv[],
void fuse_teardown(struct fuse *fuse, int fd, char *mountpoint)
{
+ (void) fd;
+
if (fuse_instance != fuse)
fprintf(stderr, "fuse: fuse_teardown() with unknown fuse object\n");
else
diff --git a/lib/mount.c b/lib/mount.c
index f7a5299..62e2b4a 100644
--- a/lib/mount.c
+++ b/lib/mount.c
@@ -86,6 +86,11 @@ int fuse_mount(const char *mountpoint, const char *opts)
int res;
int rv;
+ if (!mountpoint) {
+ fprintf(stderr, "fuse: missing mountpoint\n");
+ return -1;
+ }
+
res = socketpair(PF_UNIX, SOCK_STREAM, 0, fds);
if(res == -1) {
perror("fuse: socketpair() failed");