summaryrefslogtreecommitdiff
path: root/sql/nt_servc.cc
diff options
context:
space:
mode:
authorVladislav Vaintroub <vvaintroub@mysql.com>2008-11-22 01:10:38 +0100
committerVladislav Vaintroub <vvaintroub@mysql.com>2008-11-22 01:10:38 +0100
commitbebde5dba03a9c87b23d3517b670079ee57bd4da (patch)
treed309d03c25d55f84845346718e4ef861e3cd6b50 /sql/nt_servc.cc
parent50afc54efa24f82bd5493d227b34ca1dd3faa5f6 (diff)
parentf2a610e1e072f3b50709be3f419ea3ac1d7a3aa5 (diff)
downloadmariadb-git-bebde5dba03a9c87b23d3517b670079ee57bd4da.tar.gz
merge
Diffstat (limited to 'sql/nt_servc.cc')
-rw-r--r--sql/nt_servc.cc19
1 files changed, 12 insertions, 7 deletions
diff --git a/sql/nt_servc.cc b/sql/nt_servc.cc
index 7ff06d5bdf5..f41fa08f828 100644
--- a/sql/nt_servc.cc
+++ b/sql/nt_servc.cc
@@ -255,10 +255,6 @@ void NTService::ServiceMain(DWORD argc, LPTSTR *argv)
if (!pService->StartService())
goto error;
- // Check that the service is now running.
- if (!pService->SetStatus(SERVICE_RUNNING,NO_ERROR, 0, 0, 0))
- goto error;
-
// wait for exit event
WaitForSingleObject (pService->hExitEvent, INFINITE);
@@ -274,9 +270,18 @@ error:
return;
}
-/**
- starts the appliaction thread.
-*/
+
+
+void NTService::SetRunning()
+{
+ if (pService)
+ pService->SetStatus(SERVICE_RUNNING,NO_ERROR, 0, 0, 0);
+}
+
+
+/* ------------------------------------------------------------------------
+ StartService() - starts the application thread
+ -------------------------------------------------------------------------- */
BOOL NTService::StartService()
{