From: Billy Laws blaws05@gmail.com
--- dlls/msi/package.c | 46 ++++++++++++++++++++++++++++++---------------- 1 file changed, 30 insertions(+), 16 deletions(-)
diff --git a/dlls/msi/package.c b/dlls/msi/package.c index 89b4c09dfa4..699c599c410 100644 --- a/dlls/msi/package.c +++ b/dlls/msi/package.c @@ -1158,27 +1158,41 @@ static UINT parse_suminfo( MSISUMMARYINFO *si, MSIPACKAGE *package ) return ERROR_SUCCESS; }
+static BOOLEAN validate_package_platform( enum platform platform ) +{ + USHORT proc_machine, native_machine; + IsWow64Process2( GetCurrentProcess(), &proc_machine, &native_machine ); + switch (platform) + { + case PLATFORM_UNRECOGNIZED: + return TRUE; + case PLATFORM_INTEL: + return native_machine == IMAGE_FILE_MACHINE_I386 || + native_machine == IMAGE_FILE_MACHINE_AMD64 || + native_machine == IMAGE_FILE_MACHINE_ARM64; + case PLATFORM_X64: + return native_machine == IMAGE_FILE_MACHINE_AMD64 || + native_machine == IMAGE_FILE_MACHINE_ARM64; + case PLATFORM_ARM: + return native_machine == IMAGE_FILE_MACHINE_ARM; + case PLATFORM_ARM64: + return native_machine == IMAGE_FILE_MACHINE_ARM64; + case PLATFORM_INTEL64: + default: + return FALSE; + } +} + static UINT validate_package( MSIPACKAGE *package ) { UINT i;
- if (package->platform == PLATFORM_INTEL64) - return ERROR_INSTALL_PLATFORM_UNSUPPORTED; -#ifndef __arm__ - if (package->platform == PLATFORM_ARM) - return ERROR_INSTALL_PLATFORM_UNSUPPORTED; -#endif -#ifndef __aarch64__ - if (package->platform == PLATFORM_ARM64) + if (!validate_package_platform( package->platform )) return ERROR_INSTALL_PLATFORM_UNSUPPORTED; -#endif - if (package->platform == PLATFORM_X64) - { - if (!is_64bit && !is_wow64) - return ERROR_INSTALL_PLATFORM_UNSUPPORTED; - if (package->version < 200) - return ERROR_INSTALL_PACKAGE_INVALID; - } + + if (package->platform == PLATFORM_X64 && package->version < 200) + return ERROR_INSTALL_PACKAGE_INVALID; + if (!package->num_langids) { return ERROR_SUCCESS;
Hi,
It looks like your patch introduced the new failures shown below. Please investigate and fix them before resubmitting your patch. If they are not new, fixing them anyway would help a lot. Otherwise please ask for the known failures list to be updated.
The tests also ran into some preexisting test failures. If you know how to fix them that would be helpful. See the TestBot job for the details:
The full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=149738
Your paranoid android.
=== debian11b (64 bit WoW report) ===
kernel32: comm.c:1586: Test failed: Unexpected time 1000, expected around 500
user32: win.c:4073: Test succeeded inside todo block: Expected active window 00000000026B0162, got 00000000026B0162. win.c:4074: Test succeeded inside todo block: Expected focus window 00000000026B0162, got 00000000026B0162.
Hans Leidekker (@hans) commented about dlls/msi/package.c:
return ERROR_SUCCESS;
}
+static BOOLEAN validate_package_platform( enum platform platform ) +{
`BOOL validate_package_platform( enum platform platform )`
Hans Leidekker (@hans) commented about dlls/msi/package.c:
return ERROR_SUCCESS;
}
+static BOOLEAN validate_package_platform( enum platform platform ) +{
- USHORT proc_machine, native_machine;
- IsWow64Process2( GetCurrentProcess(), &proc_machine, &native_machine );
- switch (platform)
- {
- case PLATFORM_UNRECOGNIZED:
return TRUE;
PLATFORM_UNRECOGNIZED is handled already so this won't be reached.