Commit graph

16 commits

Author SHA1 Message Date
Jérôme Gardou e470b58376 [REACTOS] Explicitly link against pseh & include pseh headers in a few places 2021-04-28 13:10:23 +02:00
Eric Kohl 0625eb3746 [SERVICES][ADVAPI32] Support the security process aka lsass.exe
- Reserve the pipe NtControlPipe0 for the security process.
- Count regular service control pipes from 1.
- Use I_ScIsSecurityProcess to identify the security process.
- Services.exe uses the SECURITY_SERVICES_STARTED event to notify the security process that NtControlPipe0 is ready for use.
2019-08-31 17:24:47 +02:00
Timo Kreuzer f5f6ea2965 [REACTOS] Fix 64 bit issues 2019-03-04 21:58:42 +01:00
Pierre Schweitzer 29b46995aa
[ADVAPI32] When starting or sending a control to a service, set the tag in the TEB
This now allows tracking the threads of the services thanks to their tag.

This fixes the failing test in advapi32:ServiceEnv
2018-12-30 21:44:39 +01:00
Eric Kohl bf1e655172 [ADVAPI32] Stop the service dispatcher thread only if a SERVICE_CONTROL_STOP command was sent 2018-07-29 23:40:36 +02:00
Serge Gautherie 8c312fe7e1 [ADVAPI32] Fix 2 TRACE() format copypastas. 2018-05-03 08:10:43 +02:00
Eric Kohl db60cd219c [ADVAPI32] SEH-protext the calls to service control handlers
ScControlService:
- SEH-protext the calls to service control handlers.
- Return ERROR_EXCEPTION_IN_SERVICE if a service control handler throws an exception.
- Return ERROR_SERVICE_CANNOT_ACCEPT_CTRL if no service control handler has been registered for the service.
2018-05-02 23:24:26 +02:00
Eric Kohl aba6ce5b84 [ADVAPI32] Ignore the return value of the HandlerFunctionEx as well
Ignore the return value of the HandlerFunctionEx because we already ignore the return value of the HandlerFunction.
This fixes a winetest failure.
2018-04-19 06:09:57 +02:00
Eric Kohl 94435b53d7 [ADVAPI32] Revert unnecessary changes, clarify comments and clean-up inconsistencies 2018-03-25 12:03:07 +02:00
Eric Kohl 51bbab834c [ADVAPI32] Add or improve TRACE messages in the service manager functions 2018-03-25 03:20:34 +02:00
Hermès Bélusca-Maïto 295ea36f9e
[ADVAPI32] Few improvements for Services.
- Set some last errors.
- Fix error code returned by ScLookupServiceByServiceName().
- Check the validity of the handler proc in RegisterServiceCtrlHandler(Ex)W().
- Improve some traces; comment some code.
2018-02-26 00:37:09 +01:00
Hermès Bélusca-Maïto 2e3f80f940
[ADVAPI32] Code formatting + improve two traces. 2018-02-26 00:37:05 +01:00
Hermès Bélusca-Maïto 0c44925ec1
[ADVAPI32] ScStartService(): Just start the thread straight ahead, and return a suitable error code if thread creation failed. 2018-02-26 00:37:01 +01:00
Hermès Bélusca-Maïto 91b50f9ccb
[ADVAPI32] Take into account the service handler context when dispatching a control notification to a service. (Used e.g. by tcpsvcs.) 2018-02-26 00:36:57 +01:00
Eric Kohl 1dfbed9c3d [SERVICES][ADVAPI32] Fix the broken service stop sequence
services\database.c:
- Refactor ScmControlService() so that it can be used to send the dispatcher loop stop command.
- Separate the code to decrement the image run counter from the service image cleanup code.

services\rpcserver.c:
- RSetServiceStatus(): Stop the dispatcher loop when the image run counter is zero and remove the service image after that.

advapi32\service\sctrl.c:
- Do not terminate the service dispatcher loop when the last service is being stopped. Wait for an explicit dispatcher stop command (empty service name).

CORE-12413
2018-02-24 11:14:05 +01:00
Colin Finck c2c66aff7d Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
Renamed from reactos/dll/win32/advapi32/service/sctrl.c (Browse further)