Fix absolute paths to dotnet (#597)

This commit is contained in:
Justin Kotalik 2018-02-20 15:03:37 -08:00 committed by GitHub
parent c395db12e6
commit ff496ca580
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 13 additions and 9 deletions

View File

@ -188,15 +188,19 @@ HOSTFXR_UTILITY::GetHostFxrParameters(
{ {
// Check if hostfxr is in this folder, if it is, we are a standalone application, // Check if hostfxr is in this folder, if it is, we are a standalone application,
// else we assume we received an absolute path to dotnet.exe // else we assume we received an absolute path to dotnet.exe
hr = GetStandaloneHostfxrParameters( if (!struExeLocation.EndsWith(L"dotnet.exe") &&
struExeLocation.QueryStr(), !struExeLocation.EndsWith(L"dotnet"))
pcwzApplicationPhysicalPath, {
pcwzArguments, hr = GetStandaloneHostfxrParameters(
hEventLog, struExeLocation.QueryStr(),
struHostFxrDllLocation, pcwzApplicationPhysicalPath,
pdwArgCount, pcwzArguments,
ppwzArgv); hEventLog,
goto Finished; struHostFxrDllLocation,
pdwArgCount,
ppwzArgv);
goto Finished;
}
} }
else else
{ {