]> gitweb.factorcode.org Git - factor.git/blob - vm/main-windows-nt.c
Merge branch 'master' into experimental (untested!)
[factor.git] / vm / main-windows-nt.c
1 #include <windows.h>
2 #include <stdio.h>
3 #include <shellapi.h>
4 #include "master.h"
5
6 int WINAPI WinMain(
7         HINSTANCE hInstance,
8         HINSTANCE hPrevInstance,
9         LPSTR lpCmdLine,
10         int nCmdShow)
11 {
12         LPWSTR *szArglist;
13         int nArgs;
14
15         szArglist = CommandLineToArgvW(GetCommandLineW(), &nArgs);
16         if(NULL == szArglist)
17         {
18                 puts("CommandLineToArgvW failed");
19                 return 1;
20         }
21
22         init_factor_from_args(NULL,nArgs,szArglist,false);
23
24         LocalFree(szArglist);
25
26         return 0;
27 }