Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mount_darwin.go should be rewritten in Go #46

Closed
akalin opened this issue May 7, 2015 · 3 comments
Closed

mount_darwin.go should be rewritten in Go #46

akalin opened this issue May 7, 2015 · 3 comments

Comments

@akalin
Copy link
Contributor

akalin commented May 7, 2015

mount_darwin.go has a huge C function mountfuse(), which looks like it was taken from Russ Cox's library. I ran into some unexplained hangs on panic, and I strongly suspect this function, specifically the fork() -- if I return before the fork, everything works okay, and otherwise it hangs.

I suspect that plain C fork() doesn't play well with Go. The whole function can probably be rewritten to be in Go, except maybe for getvfsbyname().

Also, errp is freed, but *errp should also be freed.

@akalin
Copy link
Contributor Author

akalin commented May 7, 2015

Looks like the right solution is to basically do what Bazil does: see https://github.com/bazil/fuse/blob/eac17d5a9d20b5ceb0080721ac0e4463886e42c0/mount_darwin.go and https://github.com/bazil/fuse/blob/master/doc/mount-sequence.md -- as a side effect, this also solves #43 (apparently on darwin we have to wait for the mount command to finish).

@hanwen
Copy link
Owner

hanwen commented May 7, 2015

Yeah, I was going to suggest looking at bazil too.

Op do 7 mei 2015 18:09 schreef Fred Akalin notifications@github.com:

Looks like the right solution is to basically do what Bazil does: see
https://github.com/bazil/fuse/blob/eac17d5a9d20b5ceb0080721ac0e4463886e42c0/mount_darwin.go
and https://github.com/bazil/fuse/blob/master/doc/mount-sequence.md -- as
a side effect, this also solves #43
#43 (apparently on darwin we
have to wait for the mount command to finish).


Reply to this email directly or view it on GitHub
#46 (comment).

@hanwen hanwen closed this as completed Jul 29, 2016
@hanwen
Copy link
Owner

hanwen commented Jul 29, 2016

this is fixed in ebe08a8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants