1
0

Fix running as a service.

Two problems identified, both traced to commit 4315a11

(main.cpp) ParseArguments() was no longer being called before checking cRoot::m_RunAsService.
This led to m_RunAsService never being set (we use -d on the command line to instigate a service start).

(Root.cpp) Terminate events were being ignored when running as a service.
We only need to ignore the cin.good() call, not terminate events as a whole.
This commit is contained in:
Anthony Birkett
2016-01-21 15:22:05 +00:00
parent 85e534b745
commit d75168ca03
2 changed files with 6 additions and 10 deletions

View File

@@ -495,6 +495,9 @@ int main(int argc, char ** argv)
}
#endif
// Make sure m_RunAsService is set correctly before checking it's value
ParseArguments(argc, argv);
// Attempt to run as a service
if (cRoot::m_RunAsService)
{