• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Launch daemons after user logged in
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Launch daemons after user logged in


  • Subject: Re: Launch daemons after user logged in
  • From: Ben Greenfield <email@hidden>
  • Date: Fri, 15 May 2009 13:59:26 -0400


On May 15, 2009, at 1:38 PM, Susan Granger wrote:

Hello List,

I am using two daemons for my application to use.
One of these daemon is using Quartz API.

Consider Daemon1 & Daemon2 , In which Daemon2 is Using Quartz API.
Daemon2 can't be launch before login.

So I am trying to launch it from Daemon1.

By using the code snippet below Daemon2 crashed throwing some Untrusted Apps can't.....

while(true)
{
   CFMachPortRef port = CGWindowServerCFMachPort();
   if(port != NULL)
   {
       system("launchctl load /Library/LaunchDaemons/Daemon2.plist");
       system("launchctl start Daemon2");
       CFRelease(port);
       break;
  }
}



I reached to the conclusion that Daemon2 need to launch after user crossed the login window.

Wouldn't launching deamon2 on login and notify demon1 it is up work for you?


Ben






Sitting in Daemon1 how can I get notification that a user has logged in?



Thanks,

Susan
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden

_______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >Launch daemons after user logged in (From: Susan Granger <email@hidden>)

  • Prev by Date: Launch daemons after user logged in
  • Next by Date: Re: Launch daemons after user logged in
  • Previous by thread: Launch daemons after user logged in
  • Next by thread: Re: Launch daemons after user logged in
  • Index(es):
    • Date
    • Thread