Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
go-fuse
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Levin Zimmermann
go-fuse
Commits
00d53976
Commit
00d53976
authored
Jan 12, 2018
by
Han-Wen Nienhuys
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Run load_osxfusefs if globbing the fuse device fails on OSX
Thanks to alexanderharm for suggesting this fix.
parent
14c30156
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
2 deletions
+17
-2
fuse/mount_darwin.go
fuse/mount_darwin.go
+17
-2
No files found.
fuse/mount_darwin.go
View file @
00d53976
...
...
@@ -20,9 +20,21 @@ func openFUSEDevice() (*os.File, error) {
return
nil
,
err
}
if
len
(
fs
)
==
0
{
// TODO(hanwen): run the load_osxfuse command.
return
nil
,
fmt
.
Errorf
(
"no FUSE devices found"
)
bin
:=
oldLoadBin
if
_
,
err
:=
os
.
Stat
(
newLoadBin
);
err
==
nil
{
bin
=
newLoadBin
}
cmd
:=
exec
.
Command
(
bin
)
if
err
:=
cmd
.
Run
();
err
!=
nil
{
return
nil
,
err
}
fs
,
err
=
filepath
.
Glob
(
"/dev/osxfuse*"
)
if
err
!=
nil
{
return
nil
,
err
}
}
for
_
,
fn
:=
range
fs
{
f
,
err
:=
os
.
OpenFile
(
fn
,
os
.
O_RDWR
,
0
)
if
err
!=
nil
{
...
...
@@ -34,6 +46,9 @@ func openFUSEDevice() (*os.File, error) {
return
nil
,
fmt
.
Errorf
(
"all FUSE devices busy"
)
}
const
oldLoadBin
=
"/Library/Filesystems/osxfusefs.fs/Support/load_osxfusefs"
const
newLoadBin
=
"/Library/Filesystems/osxfuse.fs/Contents/Resources/load_osxfuse"
const
oldMountBin
=
"/Library/Filesystems/osxfusefs.fs/Support/mount_osxfusefs"
const
newMountBin
=
"/Library/Filesystems/osxfuse.fs/Contents/Resources/mount_osxfuse"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment