diff options
author | Ted Unangst <tedu@cvs.openbsd.org> | 2014-05-19 13:43:31 +0000 |
---|---|---|
committer | Ted Unangst <tedu@cvs.openbsd.org> | 2014-05-19 13:43:31 +0000 |
commit | 71588156cc3061c6dfb4c6a84029e8dcf4f723a1 (patch) | |
tree | f00db10415fde73da56e39904024a50420a52e29 /lib/libfuse | |
parent | 4bb0f99490c491ae475667192f5fec8bb1f29c1c (diff) |
as reported by Helg, should use realpath for mounts. ok guenther syl
Diffstat (limited to 'lib/libfuse')
-rw-r--r-- | lib/libfuse/fuse.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libfuse/fuse.c b/lib/libfuse/fuse.c index 6d8b5cdc0b8..16d9376e6ce 100644 --- a/lib/libfuse/fuse.c +++ b/lib/libfuse/fuse.c @@ -1,4 +1,4 @@ -/* $OpenBSD: fuse.c,v 1.21 2014/03/24 07:24:32 syl Exp $ */ +/* $OpenBSD: fuse.c,v 1.22 2014/05/19 13:43:30 tedu Exp $ */ /* * Copyright (c) 2013 Sylvestre Gallon <ccna.syl@gmail.com> * @@ -153,7 +153,7 @@ fuse_mount(const char *dir, unused struct fuse_args *args) if (fc == NULL) return (NULL); - fc->dir = strdup(dir); + fc->dir = realpath(dir, NULL); if (fc->dir == NULL) goto bad; @@ -163,7 +163,7 @@ fuse_mount(const char *dir, unused struct fuse_args *args) } fargs.fd = fc->fd; - if (mount(MOUNT_FUSEFS, dir, 0, &fargs)) { + if (mount(MOUNT_FUSEFS, fc->dir, 0, &fargs)) { switch (errno) { case EMFILE: errcause = "mount table full"; |