Mountpoint does not have to exist on macOS
macFUSE will create the mounpoint (in case it does not exist) before mounting the volume. This allows unprivileged users to mount volumes under /Volumes.
This commit is contained in:
parent
a9eb71cb1c
commit
ed0825440c
10
sshfs.c
10
sshfs.c
|
|
@ -3798,6 +3798,16 @@ static int sshfs_opt_proc(void *data, const char *arg, int key,
|
|||
sshfs.mountpoint = strdup(arg);
|
||||
} else {
|
||||
sshfs.mountpoint = realpath(arg, NULL);
|
||||
#ifdef __APPLE__
|
||||
if (!sshfs.mountpoint) {
|
||||
/*
|
||||
* The mountpoint does not exist, yet.
|
||||
* macFUSE will try to create it before
|
||||
* mounting the volume.
|
||||
*/
|
||||
sshfs.mountpoint = strdup(arg);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
if (!sshfs.mountpoint) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue