Re: What if process crashes while holding a locked semaphore?
site_archiver@lists.apple.com Delivered-To: darwin-kernel@lists.apple.com On 2009 Apr 01, at 19:33, Quinn wrote: _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-kernel mailing list (Darwin-kernel@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-kernel/site_archiver%40lists.a... When using Mach ports like this, you have to be very careful about bootstrap namespaces. Each process inherits a reference to a bootstrap namespace, meaning that which namespace it registers in depends on how it was launched. A port registration will only fail if the conflicting process is in the same namespace. This may or may not be what you want. TN2083 has all the gory details. Thanks, Quinn. I believe I'm OK since my mutually-exclusive processes are all current-user agents launched by launchd to fulfill tasks in ~/ Library/LaunchAgents. So, I am obeying the "rules to remember" in TN2083, and they should all be in the same namespace. I've added your comments to my code for future reference. Maybe when needed I'll be able to find a nice Cocoa interface to Unix Domain Sockets. This email sent to site_archiver@lists.apple.com
participants (1)
-
Jerry Krinock