aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/ext/NetFx/ca/netfxca.cpp18
1 files changed, 13 insertions, 5 deletions
diff --git a/src/ext/NetFx/ca/netfxca.cpp b/src/ext/NetFx/ca/netfxca.cpp
index 57eb96b1..06128f32 100644
--- a/src/ext/NetFx/ca/netfxca.cpp
+++ b/src/ext/NetFx/ca/netfxca.cpp
@@ -977,12 +977,20 @@ extern "C" UINT __stdcall DotNetCompatibilityCheck(
977 WcaLog(LOGMSG_VERBOSE, "Command: %ls %ls", pwzNetCoreCheckFilePath, pwzCommandLine); 977 WcaLog(LOGMSG_VERBOSE, "Command: %ls %ls", pwzNetCoreCheckFilePath, pwzCommandLine);
978 978
979 hr = ProcExec(pwzNetCoreCheckFilePath, pwzCommandLine, SW_HIDE, &hProcess); 979 hr = ProcExec(pwzNetCoreCheckFilePath, pwzCommandLine, SW_HIDE, &hProcess);
980 ExitOnFailure(hr, "failed to run NetCoreCheck from binary '%ls' with command line: %ls %ls", pwzNetCoreCheckBinaryId, pwzNetCoreCheckFilePath, pwzCommandLine); 980 if (hr == HRESULT_FROM_WIN32(ERROR_EXE_MACHINE_TYPE_MISMATCH) || hr == HRESULT_FROM_WIN32(ERROR_BAD_EXE_FORMAT))
981 {
982 dwExitCode = 13;
983 WcaLog(LOGMSG_VERBOSE, "NetCoreCheck executable for platform %ls is not compatible with current OS", pwzPlatform);
984 }
985 else
986 {
987 ExitOnFailure(hr, "failed to run NetCoreCheck from binary '%ls' with command line: %ls %ls", pwzNetCoreCheckBinaryId, pwzNetCoreCheckFilePath, pwzCommandLine);
981 988
982 hr = ProcWaitForCompletion(hProcess, INFINITE, &dwExitCode); 989 hr = ProcWaitForCompletion(hProcess, INFINITE, &dwExitCode);
983 ExitOnFailure(hr, "failed to finish NetCoreCheck from binary '%ls' with command line: %ls %ls", pwzNetCoreCheckBinaryId, pwzNetCoreCheckFilePath, pwzCommandLine); 990 ExitOnFailure(hr, "failed to finish NetCoreCheck from binary '%ls' with command line: %ls %ls", pwzNetCoreCheckBinaryId, pwzNetCoreCheckFilePath, pwzCommandLine);
984 WcaLog(LOGMSG_VERBOSE, "Exit code: %lu", dwExitCode); 991 WcaLog(LOGMSG_VERBOSE, "Exit code: %lu", dwExitCode);
985 ReleaseHandle(hProcess); 992 ReleaseHandle(hProcess);
993 }
986 994
987 hr = WcaSetIntProperty(pwzProperty, dwExitCode); 995 hr = WcaSetIntProperty(pwzProperty, dwExitCode);
988 ExitOnFailure(hr, "failed to set NetCoreCheck result in %ls", pwzProperty); 996 ExitOnFailure(hr, "failed to set NetCoreCheck result in %ls", pwzProperty);