Re: Mac OS Leopard: how to spawn an child "application"?
Re: Mac OS Leopard: how to spawn an child "application"?
- Subject: Re: Mac OS Leopard: how to spawn an child "application"?
- From: Kyle Sluder <email@hidden>
- Date: Sat, 11 Jun 2011 10:26:17 -0700
On Sat, Jun 11, 2011 at 9:59 AM, Nick <email@hidden> wrote:
> I found parent-child connected (socketpair) sockets/pipes to be the easiest
> way to set up a conversation between an agent and that peruser application
> in Dock. And in Snow Leopard it works.
Okay, it makes one thing easy (IPC) and another thing harder (making
your app actually function). :)
> This "per user" idea does not let me use any advertisement-based IPCs (like
> user domain sockets or bonjour ). I need some "per user only" IPC - so other
> user's instance of the process does not interfere with the current user's
> one.
>
> >
> I've heard that Mach Ports can be set to be seen only in the current login
> session (i.e., by current user's apps), but search led me to conclusion this
> is rather a messy/few documented (for usermode applications) topic and it
> behaves differently for Leopard and Snow Leopard due to some changes in
> "bootstrap context"
The per-user bootstrap namespace has existed since Leopard.
http://developer.apple.com/library/mac/#technotes/tn2005/tn2083#SECNAMESPACEHIERARCHY
Granted, using Mach facilities directly is considered bad form by
Apple, but I'd suggest experimenting with configuring your launchd
plist and using NSConnection to set up DO. But if anyone knows of any
gremlins, it would be helpful to mention them.
--Kyle Sluder
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden