write: Use wide-char string literals.
Signed-off-by: Michael Stefaniuc <mstefani@winehq.org> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
b3a5662c49
commit
48964553f0
|
@ -25,17 +25,15 @@
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
#include "resources.h"
|
#include "resources.h"
|
||||||
|
|
||||||
static const WCHAR SZ_WORDPAD[] = {'\\','w','o','r','d','p','a','d','.','e','x','e',0};
|
|
||||||
|
|
||||||
int CALLBACK WinMain(HINSTANCE hInstance, HINSTANCE hOldInstance, LPSTR szCmdParagraph, int res)
|
int CALLBACK WinMain(HINSTANCE hInstance, HINSTANCE hOldInstance, LPSTR szCmdParagraph, int res)
|
||||||
{
|
{
|
||||||
WCHAR path[MAX_PATH];
|
WCHAR path[MAX_PATH];
|
||||||
STARTUPINFOW stinf;
|
STARTUPINFOW stinf;
|
||||||
PROCESS_INFORMATION info;
|
PROCESS_INFORMATION info;
|
||||||
|
|
||||||
if (!GetSystemDirectoryW(path, MAX_PATH - 1 - lstrlenW(SZ_WORDPAD)))
|
if (!GetSystemDirectoryW(path, MAX_PATH - 1 - lstrlenW(L"\\wordpad.exe")))
|
||||||
goto failed;
|
goto failed;
|
||||||
lstrcatW(path, SZ_WORDPAD);
|
lstrcatW(path, L"\\wordpad.exe");
|
||||||
|
|
||||||
stinf.cb = sizeof(STARTUPINFOW);
|
stinf.cb = sizeof(STARTUPINFOW);
|
||||||
GetStartupInfoW(&stinf);
|
GetStartupInfoW(&stinf);
|
||||||
|
|
Loading…
Reference in New Issue