Permalink
Browse files

am 7798a61: Merge "Fix a possible off-by-one in the verifier."

* commit '7798a614753251adf7a77835792d78db2e93f5ff':
  Fix a possible off-by-one in the verifier.
  • Loading branch information...
2 parents 8ca227e + 7798a61 commit f31a6f7b1648c079e45a519ed3dd84f7c1b5f768 @enh enh committed with Android Git Automerger Jul 3, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 vm/analysis/CodeVerify.cpp
View
2 vm/analysis/CodeVerify.cpp
@@ -3737,7 +3737,7 @@ static bool doCodeVerification(VerifierData* vdata, RegisterTable* regTable)
if (instr == kPackedSwitchSignature ||
instr == kSparseSwitchSignature ||
instr == kArrayDataSignature ||
- (instr == OP_NOP &&
+ (instr == OP_NOP && (insnIdx + 1 < insnsSize) &&
(meth->insns[insnIdx+1] == kPackedSwitchSignature ||
meth->insns[insnIdx+1] == kSparseSwitchSignature ||
meth->insns[insnIdx+1] == kArrayDataSignature)))

0 comments on commit f31a6f7

Please sign in to comment.