diff options
author | Bram Moolenaar <Bram@vim.org> | 2019-04-03 20:31:00 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2019-04-03 20:31:00 +0200 |
commit | 796cc42d3a4fc7a940da87831a111eeb6b7a5cf3 (patch) | |
tree | 475eb4004310f0ce6d7753237656053e7349072b /src/os_w32exe.c | |
parent | 0eb035c974c47e65d32439b48e5a056b370ad429 (diff) | |
download | vim-git-796cc42d3a4fc7a940da87831a111eeb6b7a5cf3.tar.gz |
patch 8.1.1104: MS-Windows: not all environment variables can be usedv8.1.1104
Problem: MS-Windows: not all environment variables can be used.
Solution: Use the wide version of WinMain() and main(). (Ken Takata,
closes #4206)
Diffstat (limited to 'src/os_w32exe.c')
-rw-r--r-- | src/os_w32exe.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/os_w32exe.c b/src/os_w32exe.c index 6c45ec2ea..769a85191 100644 --- a/src/os_w32exe.c +++ b/src/os_w32exe.c @@ -28,20 +28,22 @@ void _cdecl SaveInst(HINSTANCE hInst); #endif #ifndef PROTO +# ifdef FEAT_GUI int WINAPI -WinMain( +wWinMain( HINSTANCE hInstance, HINSTANCE hPrevInst UNUSED, - LPSTR lpszCmdLine UNUSED, + LPWSTR lpszCmdLine UNUSED, int nCmdShow UNUSED) +# else + int +wmain(int argc UNUSED, wchar_t **argv UNUSED) +# endif { - int argc = 0; - char **argv = NULL; - # ifdef FEAT_GUI SaveInst(hInstance); # endif - VimMain(argc, argv); + VimMain(0, NULL); return 0; } |