mirror of
git://source.winehq.org/git/wine.git
synced 2024-09-15 07:28:47 +00:00
ntdll: Fix tail padding in mark_block_tail().
This commit is contained in:
parent
c8362ef8d1
commit
0fc9a9e426
|
@ -3127,7 +3127,6 @@ static void test_block_layout( HANDLE heap, DWORD global_flags, DWORD heap_flags
|
|||
ok( !memcmp( ptr1 + alloc_size, tail_buf, tail_size ), "missing block tail\n" );
|
||||
ok( !memcmp( ptr2 + alloc_size, tail_buf, tail_size ), "missing block tail\n" );
|
||||
|
||||
todo_wine_if( global_flags & FLG_HEAP_ENABLE_FREE_CHECK )
|
||||
ok( !memcmp( ptr0 + alloc_size + tail_size, padd_buf, 2 * sizeof(void *) ), "unexpected padding\n" );
|
||||
|
||||
tmp_ptr = (void *)0xdeadbeef;
|
||||
|
|
|
@ -500,8 +500,8 @@ static inline void mark_block_tail( struct block *block, DWORD flags )
|
|||
if (flags & HEAP_ADD_USER_INFO)
|
||||
{
|
||||
if (flags & HEAP_TAIL_CHECKING_ENABLED || RUNNING_ON_VALGRIND) tail += BLOCK_ALIGN;
|
||||
valgrind_make_writable( tail + sizeof(void *), sizeof(void *) );
|
||||
memset( tail + sizeof(void *), 0, sizeof(void *) );
|
||||
valgrind_make_writable( tail, BLOCK_ALIGN );
|
||||
memset( tail, 0, BLOCK_ALIGN );
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue