Skip to content

Service_Control custom action with a SERVICE_CONTROL_STOP action request does not stop dependent services #16

@icnocop

Description

@icnocop

Hi.

Thank you for MSI Extensions.

When using the Service_Control immediate custom action, with a SERVICE_CONTROL_STOP action request, the custom action fails if the service has dependent services.

I expected the dependent services to be explicitly stopped.

Stopping a Service
http://msdn.microsoft.com/en-us/library/windows/desktop/ms686335%28v=vs.85%29.aspx

"If the service control manager (SCM) receives a SERVICE_CONTROL_STOP request for a service, it instructs the service to stop by forwarding the request to the service's ServiceMain function. However, if the SCM determines that other running services are dependent on the specified service, it will not forward the stop request. Instead, it returns ERROR_DEPENDENT_SERVICES_RUNNING. Therefore, to programmatically stop such a service, you must first enumerate and stop its dependent services."

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions