Change default action of start_ps_process to call started(). This is
overriden in base_process_service to launch the process.
failed_to_start();
}
- if (service_type == ServiceType::PROCESS || service_type == ServiceType::BGPROCESS
- || service_type == ServiceType::SCRIPTED) {
- bool start_success = start_ps_process();
- if (! start_success) {
- failed_to_start();
- }
- }
- else {
- // "internal" service
- started();
+ bool start_success = start_ps_process();
+ if (! start_success) {
+ failed_to_start();
}
}
bool ServiceRecord::start_ps_process() noexcept
{
+ // default implementation: there is no process, so we are started.
+ started();
return true;
}
class process_service : public base_process_service
{
+ // called when the process exits. The exit_status is the status value yielded by
+ // the "wait" system call.
virtual void handle_exit_status(int exit_status) noexcept override;
public: