Commit f03c3a16 authored by Alexandre Julliard's avatar Alexandre Julliard

ntdll: Only free reserved memory for HIGH_ENTROPY_VA binaries.

To avoid triggering pointer-truncation bugs in applications.
parent 6e9728be
......@@ -4397,7 +4397,7 @@ void virtual_set_large_address_space(void)
if (is_wow64())
user_space_wow_limit = ((main_image_info.ImageCharacteristics & IMAGE_FILE_LARGE_ADDRESS_AWARE) ? limit_4g : limit_2g) - 1;
#ifndef __APPLE__ /* don't free the zerofill section on macOS */
else
else if (main_image_info.DllCharacteristics & IMAGE_DLLCHARACTERISTICS_HIGH_ENTROPY_VA)
free_reserved_memory( 0, (char *)0x7ffe0000 );
#endif
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment