Commit 26f4ff1a authored by Dmitry Timoshkov's avatar Dmitry Timoshkov Committed by Alexandre Julliard

ntdll: Use PAGE_EXECUTE_READWRITE protection when allocating stubs.

parent deaae1f5
...@@ -242,7 +242,7 @@ static ULONG_PTR allocate_stub( const char *dll, const char *name ) ...@@ -242,7 +242,7 @@ static ULONG_PTR allocate_stub( const char *dll, const char *name )
{ {
SIZE_T size = MAX_SIZE; SIZE_T size = MAX_SIZE;
if (NtAllocateVirtualMemory( NtCurrentProcess(), (void **)&stubs, 0, &size, if (NtAllocateVirtualMemory( NtCurrentProcess(), (void **)&stubs, 0, &size,
MEM_COMMIT, PAGE_EXECUTE_WRITECOPY ) != STATUS_SUCCESS) MEM_COMMIT, PAGE_EXECUTE_READWRITE ) != STATUS_SUCCESS)
return 0xdeadbeef; return 0xdeadbeef;
} }
stub = &stubs[nb_stubs++]; stub = &stubs[nb_stubs++];
......
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