Verify sizes when trying to read a VBR
authorFilipe Cabecinhas <me@filcab.net>
Wed, 15 Apr 2015 08:48:08 +0000 (08:48 +0000)
committerFilipe Cabecinhas <me@filcab.net>
Wed, 15 Apr 2015 08:48:08 +0000 (08:48 +0000)
commit4c0055402f2c82d54555c98d24e2ea1a8abbe1f5
tree2b5432f3b5fac23ab4131efb2c3357a3d40da80f
parentdc374b5eb4f7cc5415cde4b9f3412ac2877b6817
Verify sizes when trying to read a VBR

Also added an assert to ReadVBR64.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@234984 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Bitcode/BitstreamReader.h
lib/Bitcode/Reader/BitstreamReader.cpp
test/Bitcode/Inputs/invalid-VBR-too-big.bc [new file with mode: 0644]
test/Bitcode/invalid.test