shell32: GetModuleFileNameW gets number of WCHARs not bytes.

This commit is contained in:
Marcus Meissner 2007-11-22 08:24:17 +01:00 committed by Alexandre Julliard
parent 15f8b80ba7
commit 08aa50ec2b
1 changed files with 1 additions and 1 deletions

View File

@ -101,7 +101,7 @@ LPWSTR* WINAPI CommandLineToArgvW(LPCWSTR lpCmdline, int* numargs)
argv=GlobalLock(hargv);
for (;;)
{
len = GetModuleFileNameW(0, (LPWSTR)(argv+1), size-sizeof(LPWSTR));
len = GetModuleFileNameW(0, (LPWSTR)(argv+1), (size-sizeof(LPWSTR))/sizeof(WCHAR));
if (!len)
{
GlobalFree(hargv);