[llvm] r304741 - [CodeView] Fix endianness bug.
Zachary Turner via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 5 15:12:24 PDT 2017
Author: zturner
Date: Mon Jun 5 17:12:23 2017
New Revision: 304741
URL: http://llvm.org/viewvc/llvm-project?rev=304741&view=rev
Log:
[CodeView] Fix endianness bug.
We should be outputting in little endian, but we were writing
in host endianness.
Modified:
llvm/trunk/lib/DebugInfo/CodeView/DebugCrossExSubsection.cpp
Modified: llvm/trunk/lib/DebugInfo/CodeView/DebugCrossExSubsection.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/DebugInfo/CodeView/DebugCrossExSubsection.cpp?rev=304741&r1=304740&r2=304741&view=diff
==============================================================================
--- llvm/trunk/lib/DebugInfo/CodeView/DebugCrossExSubsection.cpp (original)
+++ llvm/trunk/lib/DebugInfo/CodeView/DebugCrossExSubsection.cpp Mon Jun 5 17:12:23 2017
@@ -42,7 +42,9 @@ uint32_t DebugCrossModuleExportsSubsecti
Error DebugCrossModuleExportsSubsection::commit(
BinaryStreamWriter &Writer) const {
for (const auto &M : Mappings) {
- if (auto EC = Writer.writeObject(M))
+ if (auto EC = Writer.writeInteger(M.first))
+ return EC;
+ if (auto EC = Writer.writeInteger(M.second))
return EC;
}
return Error::success();
More information about the llvm-commits
mailing list