]> gitweb.factorcode.org Git - factor.git/blob - vm/main-windows-nt.cpp
Start windows factor in a spawned thread (for testing)
[factor.git] / vm / main-windows-nt.cpp
1 #include "master.hpp"
2
3 int WINAPI WinMain(
4         HINSTANCE hInstance,
5         HINSTANCE hPrevInstance,
6         LPSTR lpCmdLine,
7         int nCmdShow)
8 {
9         LPWSTR *szArglist;
10         int nArgs;
11
12         szArglist = CommandLineToArgvW(GetCommandLineW(), &nArgs);
13         if(NULL == szArglist)
14         {
15                 puts("CommandLineToArgvW failed");
16                 return 1;
17         }
18
19         factor::start_standalone_factor(nArgs,szArglist);
20         //HANDLE thread = factor::start_standalone_factor_in_new_thread(nArgs,szArglist);
21         //WaitForSingleObject(thread, INFINITE);
22
23         LocalFree(szArglist);
24
25         return 0;
26 }