Re: Launching a GUI using execl()
site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com On Feb 24, 2009, at 5:58 PM, Rakesh Singhal wrote: Sorry, if I had to put in same thread. It is related to same topic but it is a different issue. I am not that much experienced programmer like most of them are here. I will take care next time. -- Jamison Hope The PTR Group www.theptrgroup.com _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... Dude, respectfully, it's not a different issue. For months now you've been asking questions which all boil down to "I want to launch a GUI app from a daemon and XXXXX isn't working. Help?" Every time, people have said "That's because you shouldn't be launching a GUI from a daemon. Read TN2083. What are you trying to do?" And you never answer their questions. And yet here like a sucker I'm going to ask you some questions: 1. If a process running as root forks/execs another process, that child process is also going to run as root. Is it really your intention to run your GUI app as root, and not as the user who happens to be fast-user-switched in at the moment (if any)? If the answer to that question is "Yes", then goto 2. If "No", goto 3. 2. So you want your GUI to run as root. Why? DON'T DO THAT. What are you trying to accomplish? You should design your GUI app to run as a normal user, launched from within that user's login session, and to use Authorization Services to get any special privileges it needs. Goto 4. 3. So you want your GUI to run as a user, then. Good. What if there is no user logged in right now? What if there are several? Are you just going to hope that the active console session belongs to the appropriate user? What are you trying to accomplish? Goto 4. 4. What are you trying to accomplish? Please give a higher-level goal than "to launch a GUI from a daemon". If that's your only answer, I doubt anybody's going to be able or willing to help you further. This email sent to site_archiver@lists.apple.com
participants (1)
-
Jamison Hope