[RFC PATCH 11/11] msvcrt: Enable LFH for internal heaps.
Rémi Bernon
rbernon at codeweavers.com
Wed May 6 07:10:03 CDT 2020
---
dlls/msvcrt/heap.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/dlls/msvcrt/heap.c b/dlls/msvcrt/heap.c
index 31153fa5b183..ffe34726851d 100644
--- a/dlls/msvcrt/heap.c
+++ b/dlls/msvcrt/heap.c
@@ -530,7 +530,9 @@ int CDECL _set_sbh_threshold(MSVCRT_size_t threshold)
if(!sb_heap)
{
+ ULONG hci = 2;
sb_heap = HeapCreate(0, 0, 0);
+ HeapSetInformation(sb_heap, HeapCompatibilityInformation, &hci, sizeof(hci));
if(!sb_heap)
return 0;
}
@@ -867,7 +869,9 @@ int CDECL MSVCRT_strncpy_s(char *dest, MSVCRT_size_t numberOfElements,
BOOL msvcrt_init_heap(void)
{
+ ULONG hci = 2;
heap = HeapCreate(0, 0, 0);
+ HeapSetInformation(heap, HeapCompatibilityInformation, &hci, sizeof(hci));
return heap != NULL;
}
--
2.26.1
More information about the wine-devel
mailing list