site_archiver@lists.apple.com Delivered-To: Darwin-dev@lists.apple.com User-agent: Mozilla-Thunderbird 2.0.0.16 (X11/20080724) Hi Terry, thanks for the quick, and really extensive reply! Can you (or somebody) point me to a good readme/technote/book on Mac OS standards? Searching apple.com for posix_spawn() lists almost exclusively the manpages of the functions, no more. This should have been posix_spawn(), not pthread_start()... but come on, they do sound similar :-D Is this allowed behaviour for a launchd-daemon? From: http://developer.apple.com/documentation/MacOSX/Conceptual/BPSystemStartup/A... I took: [...] This includes calling the daemon function, calling fork followed by exec, or calling fork followed by exit. [...] and: [...] Do not close any stray file descriptors. [...] The documentation is not consistent in disallowed behaviour. The launchctl.plist manpage for example discourages calling fork()/exit() only for the parent process (not for the child), and only because launchd might assume it quit unexpectedly. Is pid = fork() if (pid == 0) { exec("worker"); // work exit(); } else { // do nothing } a problem? Thanks and cheers, Mario _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... Terry Lambert wrote: On Sep 25, 2008, at 9:50 AM, Mario Emmenlauer wrote: 2) I haven't tried pthread_start(), but its very likely to be equal posix_spawn() is morally equivalent to a vfork() followed by an execve(), with the ability to do a limited set of intermediate work in between. This email sent to site_archiver@lists.apple.com