mirror of
https://github.com/winfsp/winfsp.git
synced 2025-04-22 16:33:02 -05:00
dll: FspService: console mode testing
This commit is contained in:
parent
0c18b82cc2
commit
89e4e8a96c
@ -290,6 +290,10 @@ FSP_API NTSTATUS FspServiceLoop(FSP_SERVICE *Service)
|
||||
goto exit;
|
||||
}
|
||||
|
||||
/* quick check to see if service already stopped */
|
||||
WaitResult = WaitForSingleObject(FspServiceConsoleModeEvent, 0);
|
||||
if (WAIT_OBJECT_0 != WaitResult)
|
||||
{
|
||||
/* set up our console control handler */
|
||||
if (!SetConsoleCtrlHandler(FspServiceConsoleCtrlHandler, TRUE))
|
||||
{
|
||||
@ -309,6 +313,7 @@ FSP_API NTSTATUS FspServiceLoop(FSP_SERVICE *Service)
|
||||
if (Service->AcceptControl & SERVICE_ACCEPT_STOP)
|
||||
FspServiceCtrlHandler(SERVICE_CONTROL_STOP, 0, 0, Service);
|
||||
}
|
||||
}
|
||||
|
||||
Result = STATUS_SUCCESS;
|
||||
|
||||
@ -466,7 +471,7 @@ static DWORD WINAPI FspServiceConsoleModeThread(PVOID Context)
|
||||
PWSTR *Argv = Context;
|
||||
DWORD Argc;
|
||||
|
||||
for (Argc = 0; 0 != *Argv; Argc++)
|
||||
for (Argc = 0; 0 != *Argv; Argv++, Argc++)
|
||||
;
|
||||
|
||||
Service = FspServiceFromTable();
|
||||
|
Loading…
x
Reference in New Issue
Block a user