From 41e188f1481fbcfb4b2851df6834495194633057 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Hentschel?= Date: Tue, 1 Nov 2011 19:32:57 +0100 Subject: [PATCH] ntdll: Only load ARMv7 PE images when supported by CPU. --- dlls/ntdll/virtual.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/dlls/ntdll/virtual.c b/dlls/ntdll/virtual.c index 3d75fa1e30e..b23e5968287 100644 --- a/dlls/ntdll/virtual.c +++ b/dlls/ntdll/virtual.c @@ -1055,8 +1055,10 @@ static NTSTATUS check_architecture( const IMAGE_NT_HEADERS *nt ) return STATUS_INVALID_IMAGE_FORMAT; } #elif defined(__arm__) && !defined(__ARMEB__) - if (nt->FileHeader.Machine == IMAGE_FILE_MACHINE_ARMV7 || - nt->FileHeader.Machine == IMAGE_FILE_MACHINE_ARM || + if (nt->FileHeader.Machine == IMAGE_FILE_MACHINE_ARM || +#if defined(__ARM_ARCH_7__) || defined(__ARM_ARCH_7A__) || defined(__ARM_ARCH_7R__) + nt->FileHeader.Machine == IMAGE_FILE_MACHINE_ARMV7 || +#endif nt->FileHeader.Machine == IMAGE_FILE_MACHINE_THUMB) return STATUS_SUCCESS; #endif