[llvm-commits] CVS: llvm/lib/Bitcode/Reader/BitcodeReader.cpp
Chris Lattner
sabre at nondot.org
Sun May 6 12:28:04 PDT 2007
Changes in directory llvm/lib/Bitcode/Reader:
BitcodeReader.cpp updated: 1.46 -> 1.47
---
Log message:
fix off-by-one that caused the llvm2cpp test to fail
---
Diffs of the changes: (+4 -2)
BitcodeReader.cpp | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
Index: llvm/lib/Bitcode/Reader/BitcodeReader.cpp
diff -u llvm/lib/Bitcode/Reader/BitcodeReader.cpp:1.46 llvm/lib/Bitcode/Reader/BitcodeReader.cpp:1.47
--- llvm/lib/Bitcode/Reader/BitcodeReader.cpp:1.46 Sun May 6 03:21:50 2007
+++ llvm/lib/Bitcode/Reader/BitcodeReader.cpp Sun May 6 14:27:46 2007
@@ -964,9 +964,11 @@
Section = SectionTable[Record[5]-1];
}
GlobalValue::VisibilityTypes Visibility = GlobalValue::DefaultVisibility;
- if (Record.size() >= 6) Visibility = GetDecodedVisibility(Record[6]);
+ if (Record.size() > 6)
+ Visibility = GetDecodedVisibility(Record[6]);
bool isThreadLocal = false;
- if (Record.size() >= 7) isThreadLocal = Record[7];
+ if (Record.size() > 7)
+ isThreadLocal = Record[7];
GlobalVariable *NewGV =
new GlobalVariable(Ty, isConstant, Linkage, 0, "", TheModule);
More information about the llvm-commits
mailing list