Fixed application file name (absolute path) in command line.

svn path=/trunk/; revision=566
This commit is contained in:
Eric Kohl 1999-06-26 18:24:38 +00:00
parent 8ae06e50f1
commit 4d7dcc6886

View file

@ -426,11 +426,24 @@ WINBOOL STDCALL CreateProcessW(LPCWSTR lpApplicationName,
ULONG InitialViewSize;
PROCESS_BASIC_INFORMATION ProcessBasicInfo;
ULONG retlen;
DWORD len = 0;
DPRINT("CreateProcessW(lpApplicationName '%w', lpCommandLine '%w')\n",
lpApplicationName,lpCommandLine);
wcscpy(TempCommandLine, lpApplicationName);
if (lpApplicationName[1] != ':')
{
len = GetCurrentDirectoryW(MAX_PATH,TempCommandLine);
if (TempCommandLine[len - 1] != L'\\')
{
TempCommandLine[len] = L'\\';
TempCommandLine[len + 1] = 0;
}
wcscat(TempCommandLine,lpApplicationName);
}
else
wcscpy(TempCommandLine, lpApplicationName);
if (lpCommandLine != NULL)
{
wcscat(TempCommandLine, L" ");