https://git.reactos.org/?p=reactos.git;a=commitdiff;h=98638cc2dfdde460ae4994...
commit 98638cc2dfdde460ae49941c76dd51f1b796a001 Author: Mark Jansen mark.jansen@reactos.org AuthorDate: Tue Apr 30 19:03:17 2019 +0200 Commit: Mark Jansen mark.jansen@reactos.org CommitDate: Wed May 15 19:39:56 2019 +0200
[NTOS/MM] Recognize AMD64 image in PeFmtCreateSection failure case --- ntoskrnl/mm/section.c | 4 ++++ 1 file changed, 4 insertions(+)
diff --git a/ntoskrnl/mm/section.c b/ntoskrnl/mm/section.c index 56ffab8a2ad..a8d294578fe 100644 --- a/ntoskrnl/mm/section.c +++ b/ntoskrnl/mm/section.c @@ -364,6 +364,10 @@ l_ReadHeaderFromFile: #endif // _WIN64 break;
+#ifndef _WIN64 + case IMAGE_NT_OPTIONAL_HDR64_MAGIC: + nStatus = STATUS_INVALID_IMAGE_WIN_64; +#endif default: DIE(("Unrecognized optional header, Magic is %X\n", piohOptHeader->Magic)); }