Roman Pišl : ntdll: Don't pretend that the whole address space is reserved on non-i386.

Alexandre Julliard julliard at winehq.org
Fri Feb 25 07:30:22 CST 2022


Module: wine
Branch: oldstable
Commit: 3ba8d6ea05c0c4f610c057fc2976dd263dd2b261
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=3ba8d6ea05c0c4f610c057fc2976dd263dd2b261

Author: Roman Pišl <rpisl at seznam.cz>
Date:   Wed Jun 30 14:53:47 2021 +0200

ntdll: Don't pretend that the whole address space is reserved on non-i386.

This is analogous to 61dcca5dbf4d0021f420dc87248b39a1dc1542db.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=50735
Signed-off-by: Roman Pišl <rpisl at seznam.cz>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
(cherry picked from commit 0ec555e58ea9d5b33f4c825e96965ad0cb15d00f)
Signed-off-by: Michael Stefaniuc <mstefani at winehq.org>

---

 dlls/ntdll/unix/virtual.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/dlls/ntdll/unix/virtual.c b/dlls/ntdll/unix/virtual.c
index 785583a340a..e2956c1ac97 100644
--- a/dlls/ntdll/unix/virtual.c
+++ b/dlls/ntdll/unix/virtual.c
@@ -3663,10 +3663,18 @@ static int CDECL get_free_mem_state_callback( void *start, SIZE_T size, void *ar
     else /* outside of the reserved area, pretend it's allocated */
     {
         info->RegionSize        = (char *)start - (char *)info->BaseAddress;
+#ifdef __i386__
         info->State             = MEM_RESERVE;
         info->Protect           = PAGE_NOACCESS;
         info->AllocationProtect = PAGE_NOACCESS;
         info->Type              = MEM_PRIVATE;
+#else
+        info->State             = MEM_FREE;
+        info->Protect           = PAGE_NOACCESS;
+        info->AllocationBase    = 0;
+        info->AllocationProtect = 0;
+        info->Type              = 0;
+#endif
     }
     return 1;
 }




More information about the wine-cvs mailing list