[launchd-dev] My Launch Agent is Persisting Beyond Logout

Mac QA macqaguy at gmail.com
Thu Mar 13 13:03:11 PDT 2008


On Tue, Mar 11, 2008 at 11:11 PM, Dave Zarzycki <zarzycki at apple.com> wrote:
>  Does your agent catch Unix signals?

Quick clarifying question about this Unix signal business.

Currently, if I log in 3 users via fast user switching, log out two of
them, then Activity Monitor shows 3 instances of my launch agent
running. Yet even if I try to force quit one of the launch agents
running from one of the now logged out users from Activity Monitor
(and authenticate as an administrator to do so) the process still gets
re-launched by launchd. Doesn't it seem wrong for launchd to be
RE-launching an app for a user that is no longer logged in. If I do
whatever is necessary to catch this Unix signal business and exit the
daemon that way, will it still keep getting relaunched by launchd
after the user logs out?


More information about the launchd-dev mailing list