From: xiangyong o. <ou...@cs...> - 2010-10-12 19:19:18
|
Hello Michael, I had a simple test: Program A does a fork(), then: parent-proc child-proc -------------- -------------- call fuse_main() access fuse-Filesystem call "fusermount -u" It seems it's able to work properly. However, pthread_create() doesn't do the job as fork(). What's the internal difference caused by the two approaches? Thanks! -Ouyang On Tue, Oct 12, 2010 at 2:36 PM, Michael Raskin <fb0...@ra...> wrote: > On 10/12/2010 09:00 PM, xiangyong ouyang wrote: >> Hello all, >> >> I have a fuse-based filesystem. and I want to include this filesystem >> as part of another program A. In other words, I want to implement >> this: >> >> - Program A starts a thread T; >> - T calls fuse_main() to start the fuse filesystem; >> - When A wants to exit, it calls "fusermount -u" to unmount, which in >> turn calls fuse_destroy(), and consequently, thread T exits >> >> Is that valid with FUSE? > > You need to do without fuse_main, with more basic constructions. You > need to most of the things fuse_main calls directly. > |