Re: kinfo_proc structure
Re: kinfo_proc structure
- Subject: Re: kinfo_proc structure
- From: Michael Smith <email@hidden>
- Date: Thu, 2 Jul 2009 20:22:56 -0700
On Jul 2, 2009, at 9:38 AM, Rahulkumar Tibdewal wrote: Thanks for interest MIKE. I am preparing an application where I can manage the MAC machines processes. For example: quitting the process.
There is already a perfectly good application for this included with the system; Activity Monitor.
For this I have prepared one kinfo_proc structure and populated it. Using kp_proc.p_comm and kp_proc.p_pid I am preparing a another structure CProcessEntry which has pid and process name and store that structure in vector array. Now when we pass particular name say firefox, it should be effective enough to quit firefox of only that user.
Your opinion does not define the system. To put it another way; it doesn't work like that.
If you are interested in the user-visible label associated with an application, you need to talk to a higher-level component. This used to be Launch Services; the functionality may have moved elsewhere, but that's where I'd start looking.
Another problem was we don’t have always the same name of application and process name. Example, firefox.app application has process name firefox-bin. This will fail my application. I want to handle these cases. Again I got few pointers from [mm w]. But I don’t have clear Idea of its implementation. However I also discovered one more thing about java applications run under same process name JavaApplicationStub. If I have two or more Java Application there process name is same i.e. JavaApplicationStub But There PSN are different. How can I handle these special cases?
See above.
= Mike Excellence in any department can be attained only by the labor of a lifetime; it is not to be purchased at a lesser price -- Samuel Johnson
|
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden