https://git.reactos.org/?p=reactos.git;a=commitdiff;h=d734bd784cd69a20d6899…
commit d734bd784cd69a20d6899d16c0f8a9e9e1c446ad
Author: Timo Kreuzer <timo.kreuzer(a)reactos.org>
AuthorDate: Thu Sep 12 13:37:46 2024 +0300
Commit: Timo Kreuzer <timo.kreuzer(a)reactos.org>
CommitDate: Sun Sep 15 19:28:07 2024 +0300
[WIN32KNT_APITEST] Fix NtGdiEnumFontOpen test on x64 and Win7+
---
modules/rostests/apitests/win32nt/ntgdi/NtGdiEnumFontOpen.c | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/modules/rostests/apitests/win32nt/ntgdi/NtGdiEnumFontOpen.c
b/modules/rostests/apitests/win32nt/ntgdi/NtGdiEnumFontOpen.c
index 1dcadf6f7fa..c31aaf85c0f 100644
--- a/modules/rostests/apitests/win32nt/ntgdi/NtGdiEnumFontOpen.c
+++ b/modules/rostests/apitests/win32nt/ntgdi/NtGdiEnumFontOpen.c
@@ -14,6 +14,13 @@ START_TEST(NtGdiEnumFontOpen)
ULONG ulCount;
PENTRY pEntry;
+ DWORD dwOsVer = NtCurrentPeb()->OSMajorVersion << 8 |
NtCurrentPeb()->OSMinorVersion;
+ if (dwOsVer >= _WIN32_WINNT_WIN7)
+ {
+ skip("NtGdiEnumFontOpen is not supported on Windows 7 or later\n");
+ return;
+ }
+
hDC = CreateDCW(L"DISPLAY",NULL,NULL,NULL);
// FIXME: We should load the font first
@@ -32,7 +39,7 @@ START_TEST(NtGdiEnumFontOpen)
ok(pEntry->einfo.pobj != NULL, "pEntry->einfo.pobj was NULL.\n");
ok_long(pEntry->ObjectOwner.ulObj, GetCurrentProcessId());
ok_ptr(pEntry->pUser, NULL);
- ok_int(pEntry->FullUnique, (idEnum >> 16));
+ ok_int(pEntry->FullUnique, (idEnum >> 16) & 0xFFFF);
ok_int(pEntry->Objt, GDI_OBJECT_TYPE_ENUMFONT >> 16);
ok_int(pEntry->Flags, 0);