]> granicus.if.org Git - gc/commitdiff
Fix dwSize argument of VirtualFree call in detect_GetWriteWatch (Win32)
authorIvan Maidanski <ivmai@mail.ru>
Sun, 23 Dec 2012 12:13:45 +0000 (16:13 +0400)
committerIvan Maidanski <ivmai@mail.ru>
Sun, 23 Dec 2012 15:39:39 +0000 (16:39 +0100)
* os_dep.c (detect_GetWriteWatch): Pass 0 (instead of GC_page_size)
to Win32 VirtualFree if GWW_VDB (dwSize must be 0 if MEM_RELEASE
according to MSDN).

os_dep.c

index c2957a060fd0297edeedf8865549224bdcdce02e..fcf991040d34d8e71efa6206eec9a8c4e71d7611 100644 (file)
--- a/os_dep.c
+++ b/os_dep.c
@@ -1622,7 +1622,7 @@ void GC_register_data_segments(void)
           } else {
             GetWriteWatch_alloc_flag = MEM_WRITE_WATCH;
           }
-          VirtualFree(page, GC_page_size, MEM_RELEASE);
+          VirtualFree(page, 0 /* dwSize */, MEM_RELEASE);
         } else {
           /* GetWriteWatch will be useless. */
           GetWriteWatch_func = NULL;