[llvm] r274639 - Disable hash verification of enums.
Zachary Turner via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 6 10:25:12 PDT 2016
Author: zturner
Date: Wed Jul 6 12:25:12 2016
New Revision: 274639
URL: http://llvm.org/viewvc/llvm-project?rev=274639&view=rev
Log:
Disable hash verification of enums.
Modified:
llvm/trunk/lib/DebugInfo/PDB/Raw/RawSession.cpp
llvm/trunk/lib/DebugInfo/PDB/Raw/TpiStream.cpp
Modified: llvm/trunk/lib/DebugInfo/PDB/Raw/RawSession.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/DebugInfo/PDB/Raw/RawSession.cpp?rev=274639&r1=274638&r2=274639&view=diff
==============================================================================
--- llvm/trunk/lib/DebugInfo/PDB/Raw/RawSession.cpp (original)
+++ llvm/trunk/lib/DebugInfo/PDB/Raw/RawSession.cpp Wed Jul 6 12:25:12 2016
@@ -51,6 +51,8 @@ Error RawSession::createFromPdb(StringRe
ErrorOr<std::unique_ptr<MemoryBuffer>> ErrorOrBuffer =
MemoryBuffer::getFileOrSTDIN(Path, /*FileSize=*/-1,
/*RequiresNullTerminator=*/false);
+ if (!ErrorOrBuffer)
+ return llvm::make_error<GenericError>(generic_error_code::invalid_path);
std::unique_ptr<MemoryBuffer> Buffer = std::move(*ErrorOrBuffer);
auto Stream = llvm::make_unique<InputByteStream>(std::move(Buffer));
Modified: llvm/trunk/lib/DebugInfo/PDB/Raw/TpiStream.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/DebugInfo/PDB/Raw/TpiStream.cpp?rev=274639&r1=274638&r2=274639&view=diff
==============================================================================
--- llvm/trunk/lib/DebugInfo/PDB/Raw/TpiStream.cpp (original)
+++ llvm/trunk/lib/DebugInfo/PDB/Raw/TpiStream.cpp Wed Jul 6 12:25:12 2016
@@ -105,7 +105,7 @@ public:
}
Error visitClass(ClassRecord &Rec) override { return verify(Rec); }
- Error visitEnum(EnumRecord &Rec) override { return verify(Rec); }
+ Error visitEnum(EnumRecord &Rec) override { return Error::success(); }
Error visitUnion(UnionRecord &Rec) override { return verify(Rec); }
Error visitTypeBegin(const CVRecord<TypeLeafKind> &Rec) override {
More information about the llvm-commits
mailing list