diff --git a/daemon/lokinet.cpp b/daemon/lokinet.cpp index a618e5aa7..7a20d2742 100644 --- a/daemon/lokinet.cpp +++ b/daemon/lokinet.cpp @@ -647,13 +647,16 @@ SvcCtrlHandler(DWORD dwCtrl) switch (dwCtrl) { case SERVICE_CONTROL_STOP: + // tell servicve we are stopping ReportSvcStatus(SERVICE_STOP_PENDING, NO_ERROR, 0); - // Signal the service to stop. + // do the actual tear down handle_signal(SIGINT); return; case SERVICE_CONTROL_INTERROGATE: - break; + // report status + SetServiceStatus(SvcStatusHandle, &SvcStatus); + return; default: break;