[launchd-dev] ~/LaunchAgent + KeepAlive=true = Login Jail

Quinn eskimo1 at apple.com
Mon Jan 28 03:33:36 PST 2008

At 23:16 -0700 27/1/08, James Bucanek wrote:
>The only difference is that KeepAlive would restart my background 
>app if it crashed. Fortunately (through the brilliant programming 
>efforts of its creator, I'm sure), this particular app simply 
>doesn't crash -- knock on wood.

One option is to set "KeepAlive" to a dictionary containing 
"SuccessfulExit" set to false.  That way, launchd won't restart you 
if you quit cleanly.  OTOH, if you crash, you'll be relaunched.

Quinn "The Eskimo!"                    <http://www.apple.com/developer/>
Apple Developer Relations, Developer Technical Support, Core OS/Hardware

More information about the launchd-dev mailing list