tags:

views:

48

answers:

0

My problem is not the best scenario for fork(). However, this is the best func I can get.

I am working on a Firefox plugin on Mac OSX. To make it robust, I need to create a new process to run my plugin. The problem is, when I forked a new process, much like this:

if (fork() == 0) exit(other_main());

However, since the state is not cleaned, I cannot properly initialized my new process (call NSApplicationLoad etc.). Any ideas? BTW, I certainly don't want create a new binary and exec it.