gedmurphy(a)svn.reactos.com wrote:
Improve stopping control of the service
@@ -137,14 +137,14 @@
{
case SERVICE_CONTROL_SHUTDOWN: /* fall through */
case SERVICE_CONTROL_STOP:
- bShutDownFlag = TRUE;
+ bShutDown = TRUE;
UpdateStatus(SERVICE_STOP_PENDING, -1);
break;
case SERVICE_CONTROL_PAUSE:
- bPauseFlag = TRUE;
+ bPause = TRUE;
break;
case SERVICE_CONTROL_CONTINUE:
- bPauseFlag = FALSE;
+ bPause = FALSE;
You might want to use InterlockedExchange to make it thread-safe.
- Thomas