Commit 415dfa63 authored by Eric Pouech's avatar Eric Pouech Committed by Alexandre Julliard

Fixed section mapping in PE loading when both

IMAGE_SCN_CNT_UNINITIALIZED_DATA and IMAGE_SCN_CNT_INITIALIZED_DATA are set.
parent e5aabc6e
......@@ -658,7 +658,8 @@ static NTSTATUS map_image( HANDLE hmapping, int fd, char *base, DWORD total_size
sec->PointerToRawData, sec->SizeOfRawData,
sec->Characteristics );
if (sec->Characteristics & IMAGE_SCN_CNT_UNINITIALIZED_DATA) continue;
if ((sec->Characteristics & IMAGE_SCN_CNT_UNINITIALIZED_DATA) &&
!(sec->Characteristics & IMAGE_SCN_CNT_INITIALIZED_DATA)) continue;
if (!sec->PointerToRawData || !sec->SizeOfRawData) continue;
/* Note: if the section is not aligned properly VIRTUAL_mmap will magically
......
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