ntdll: Fix the protection state of writable sections.

This commit is contained in:
Alexandre Julliard 2010-08-26 18:06:10 +02:00
parent 8e2e95ed7e
commit 5393f0a947

View file

@ -1278,7 +1278,7 @@ static NTSTATUS map_image( HANDLE hmapping, int fd, char *base, SIZE_T total_siz
size = ROUND_SIZE( sec->VirtualAddress, sec->SizeOfRawData );
if (sec->Characteristics & IMAGE_SCN_MEM_READ) vprot |= VPROT_READ;
if (sec->Characteristics & IMAGE_SCN_MEM_WRITE) vprot |= VPROT_READ|VPROT_WRITECOPY;
if (sec->Characteristics & IMAGE_SCN_MEM_WRITE) vprot |= VPROT_READ|VPROT_WRITE;
if (sec->Characteristics & IMAGE_SCN_MEM_EXECUTE) vprot |= VPROT_EXEC;
/* Dumb game crack lets the AOEP point into a data section. Adjust. */