MCPcopy Create free account
hub / github.com/dobin/RedEdr / ServiceEntry

Function ServiceEntry

RedEdrPplService/RedEdrPplService.cpp:134–151  ·  view source on GitHub ↗

Setup the service (from main)

Source from the content-addressed store, hash-verified

132
133// Setup the service (from main)
134DWORD ServiceEntry()
135{
136 DWORD retval = 0;
137 SERVICE_TABLE_ENTRY serviceTable[] =
138 {
139 {const_cast<LPWSTR>(SERVICE_NAME), (LPSERVICE_MAIN_FUNCTION)ServiceMain},
140 {NULL, NULL}
141 };
142
143 if (StartServiceCtrlDispatcher(serviceTable) == FALSE)
144 {
145 retval = GetLastError();
146 LOG_W(LOG_ERROR, L"ServiceEntry: StartServiceCtrlDispatcher error: %d", retval);
147 return retval;
148 }
149
150 return retval;
151}
152
153
154int main(INT argc, CHAR** argv)

Callers 1

mainFunction · 0.85

Calls 1

LOG_WFunction · 0.70

Tested by

no test coverage detected