[PATCH] D22750: Do not ignore SizeOfOptionalHeader in COFF header even if PE header is not present.
Marek Milkovič via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 10 03:14:14 PDT 2016
milkovic updated this revision to Diff 67497.
milkovic added a comment.
I have updated the diff with the new version. The new version checks for presence of `COFFHeader` because it may be nullified when bigobj COFF is detected. I have run all the tests and everything seems to be OK.
Thanks.
https://reviews.llvm.org/D22750
Files:
lib/Object/COFFObjectFile.cpp
Index: lib/Object/COFFObjectFile.cpp
===================================================================
--- lib/Object/COFFObjectFile.cpp
+++ lib/Object/COFFObjectFile.cpp
@@ -718,6 +718,9 @@
}
if ((EC = getObject(DataDirectory, Data, DataDirAddr, DataDirSize)))
return;
+ }
+
+ if (COFFHeader) {
CurPtr += COFFHeader->SizeOfOptionalHeader;
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D22750.67497.patch
Type: text/x-patch
Size: 373 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160810/3a293b52/attachment.bin>
More information about the llvm-commits
mailing list