Module: wine Branch: master Commit: 9559959f95cc2087511ac58dfda5fc482e306ab9 URL: https://gitlab.winehq.org/wine/wine/-/commit/9559959f95cc2087511ac58dfda5fc4...
Author: Sven Baars sbaars@codeweavers.com Date: Wed Jul 12 09:20:23 2023 +0200
kernel32/tests: Update a todo that succeeds with the new wow64 architecture.
---
dlls/kernel32/tests/thread.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-)
diff --git a/dlls/kernel32/tests/thread.c b/dlls/kernel32/tests/thread.c index cabc747fdbd..4addff1e199 100644 --- a/dlls/kernel32/tests/thread.c +++ b/dlls/kernel32/tests/thread.c @@ -853,11 +853,21 @@ static VOID test_thread_processor(void) HANDLE curthread,curproc; DWORD_PTR processMask,systemMask,retMask; SYSTEM_INFO sysInfo; - BOOL is_wow64; + BOOL is_wow64, old_wow64 = FALSE; DWORD ret;
if (!pIsWow64Process || !pIsWow64Process( GetCurrentProcess(), &is_wow64 )) is_wow64 = FALSE;
+ if (is_wow64) + { + TEB64 *teb64 = ULongToPtr(NtCurrentTeb()->GdiBatchCount); + if (teb64) + { + PEB64 *peb64 = ULongToPtr(teb64->Peb); + old_wow64 = !peb64->LdrData; + } + } + sysInfo.dwNumberOfProcessors=0; GetSystemInfo(&sysInfo); ok(sysInfo.dwNumberOfProcessors>0, @@ -904,7 +914,7 @@ static VOID test_thread_processor(void) { SetLastError(0xdeadbeef); ret = SetThreadIdealProcessor(GetCurrentThread(), MAXIMUM_PROCESSORS + 1); - todo_wine + todo_wine_if(old_wow64) ok(ret != ~0u, "Unexpected return value %lu.\n", ret);
SetLastError(0xdeadbeef);