Alexandre Julliard : ntdll: Fill the tail of existing large blocks when the debug flags change.

Alexandre Julliard julliard at winehq.org
Tue Jan 26 11:21:10 CST 2010


Module: wine
Branch: master
Commit: aa409c75f904156dab8a62e4ca669b542e64493d
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=aa409c75f904156dab8a62e4ca669b542e64493d

Author: Alexandre Julliard <julliard at winehq.org>
Date:   Tue Jan 26 16:06:59 2010 +0100

ntdll: Fill the tail of existing large blocks when the debug flags change.

---

 dlls/ntdll/heap.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/dlls/ntdll/heap.c b/dlls/ntdll/heap.c
index e112031..7cbc8ef 100644
--- a/dlls/ntdll/heap.c
+++ b/dlls/ntdll/heap.c
@@ -1341,6 +1341,7 @@ void heap_set_debug_flags( HANDLE handle )
     if (flags & (HEAP_FREE_CHECKING_ENABLED | HEAP_TAIL_CHECKING_ENABLED))  /* fix existing blocks */
     {
         SUBHEAP *subheap;
+        ARENA_LARGE *large;
 
         LIST_FOR_EACH_ENTRY( subheap, &heap->subheap_list, SUBHEAP, entry )
         {
@@ -1367,6 +1368,10 @@ void heap_set_debug_flags( HANDLE handle )
                 }
             }
         }
+
+        LIST_FOR_EACH_ENTRY( large, &heap->large_list, ARENA_LARGE, entry )
+            mark_block_tail( (char *)(large + 1) + large->data_size,
+                             large->block_size - sizeof(*large) - large->data_size, flags );
     }
 }
 




More information about the wine-cvs mailing list