[haiku-development] Re: Rely on launch daemon to shutdown a service
- From: Axel Dörfler <axeld@xxxxxxxxxxxxxxxx>
- To: haiku-development@xxxxxxxxxxxxx
- Date: Tue, 5 Apr 2016 09:10:57 +0200
Hi Dario,
Am 05/04/2016 um 01:01 schrieb Dario Casalinuovo:
shutdown_media_server, just after trying to shutdown cleanly the
media_server it's checking if it's still up and in that case kill the
process. Obviously it's a problem with the launch daemon auto-restart
and cause the restart process to stop the server twice.
Is there any way to relegate this job to the launch_daemon itself?
You can programmatically stop the launch_daemon from relaunching it
again. In the future, this will also allow to quit it (right now, this
only work with user level apps).
Have a look at BLaunchRoster::Stop() [1].
Bye,
Axel.
[1]
http://cgit.haiku-os.org/haiku/tree/headers/private/app/LaunchRoster.h#n38
Other related posts: