Relax an assert when there's a type mismatch in forward references
authorFilipe Cabecinhas <me@filcab.net>
Tue, 28 Apr 2015 20:18:47 +0000 (20:18 +0000)
committerFilipe Cabecinhas <me@filcab.net>
Tue, 28 Apr 2015 20:18:47 +0000 (20:18 +0000)
commit7acbf5611216bedb1063ebf2d92c8fd5e4ca782d
tree9e2c04852fe8622708a20c3d81cd036b703c2e99
parent5052130d6addb8bbfad085f4cea1698d4165404b
Relax an assert when there's a type mismatch in forward references

Summary:
We don't seem to need to assert here, since this function's callers expect
to get a nullptr on error. This way we don't assert on user input.

Bug found with AFL fuzz.

Reviewers: rafael

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D9308

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236027 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Bitcode/Reader/BitcodeReader.cpp
test/Bitcode/Inputs/invalid-fwdref-type-mismatch.bc [new file with mode: 0644]
test/Bitcode/invalid.test