@julliard: the paths for wow64 modules returned from kernel32 don't match windows behavior: wine returns 32bit system modules from c:\\windows\\syswow64 whereas windows returns them from c:\\windows\\system32 (except a couple of exceptions: 32bit ntdll and exe main module). Implementation in dbghelp includes the correction of this. (I opted not to change ntdll at once: testing on windows show that kernel32.EnumProcesModulesEx returns exactly the ldr_data list, and I didn't feel like adding this burden to this patch ;-).
It would need to be fixed, or dbghelp can return the wrong info for now. We definitely don't want to add complexity to dbghelp to work around ntdll bugs. -- https://gitlab.winehq.org/wine/wine/-/merge_requests/2497#note_28200