mirror of
https://github.com/debauchee/barrier.git
synced 2025-07-25 12:28:48 +02:00
Potential fix for issue 26, but needs some GUI integration
This commit is contained in:
parent
801c3112b1
commit
52564a473a
16 changed files with 423 additions and 26 deletions
|
@ -615,13 +615,14 @@ CArchDaemonWindows::serviceMain(DWORD argc, LPTSTR* argvIn)
|
|||
m_serviceState = SERVICE_START_PENDING;
|
||||
setStatus(m_serviceState, 0, 10000);
|
||||
|
||||
std::string commandLine;
|
||||
|
||||
// if no arguments supplied then try getting them from the registry.
|
||||
// the first argument doesn't count because it's the service name.
|
||||
Arguments args;
|
||||
ArgList myArgv;
|
||||
if (argc <= 1) {
|
||||
// read command line
|
||||
std::string commandLine;
|
||||
HKEY key = openNTServicesKey();
|
||||
key = CArchMiscWindows::openKey(key, argvIn[0]);
|
||||
key = CArchMiscWindows::openKey(key, _T("Parameters"));
|
||||
|
@ -685,6 +686,8 @@ CArchDaemonWindows::serviceMain(DWORD argc, LPTSTR* argvIn)
|
|||
}
|
||||
}
|
||||
|
||||
m_commandLine = commandLine;
|
||||
|
||||
try {
|
||||
// invoke daemon function
|
||||
m_daemonResult = m_daemonFunc(static_cast<int>(argc), argv);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue