> On Aug 4, 2014, at 10:41 AM, Scott Ribe <scott_r...@elevated-dev.com> wrote:
> 
> Showing my age here, but as an old UNIX troll, and assuming the apps are not 
> sandboxed, I'd just use domain sockets.
> 
> <https://developer.apple.com/library/mac/documentation/Darwin/Reference/Manpages/man4/unix.4.html>

I have done this, and it’s surprisingly painful. I’d never do it again.

_Using_ the sockets is pretty easy (assuming you enjoy implementing framing 
protocols). The hard part is that you have to have a pseudo-file, located in 
the filesystem, to represent a Unix-domain socket. So you have to find a hidden 
place to create this ‘file’ with a randomly-chosen name (unless you don’t care 
about DoS attacks), give it the proper permissions, somehow transmit knowledge 
of that location to the other app, and clean it up when you’re done.

Doing this instead of using XPC or AppleEvents is like carving your own wheel 
out of stone instead of just going to a store and buying one.

—Jens
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to