aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMike Pall <mike>2017-05-09 20:59:37 +0200
committerMike Pall <mike>2017-05-09 20:59:37 +0200
commit1c89933f129dde76944336c6bfd05297b8d67730 (patch)
treea5a019e645f700486681bda89d0794ee7bc0820f /src
parent0bf80b07b0672ce874feedcc777afe1b791ccb5a (diff)
downloadluajit-1c89933f129dde76944336c6bfd05297b8d67730.tar.gz
luajit-1c89933f129dde76944336c6bfd05297b8d67730.tar.bz2
luajit-1c89933f129dde76944336c6bfd05297b8d67730.zip
Fix LJ_MAX_JSLOTS assertion in rec_check_slots().
Thanks to Yichun Zhang.
Diffstat (limited to 'src')
-rw-r--r--src/lj_record.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lj_record.c b/src/lj_record.c
index 7b572764..cecacd21 100644
--- a/src/lj_record.c
+++ b/src/lj_record.c
@@ -81,9 +81,9 @@ static void rec_check_slots(jit_State *J)
81 BCReg s, nslots = J->baseslot + J->maxslot; 81 BCReg s, nslots = J->baseslot + J->maxslot;
82 int32_t depth = 0; 82 int32_t depth = 0;
83 cTValue *base = J->L->base - J->baseslot; 83 cTValue *base = J->L->base - J->baseslot;
84 lua_assert(J->baseslot >= 1 && J->baseslot < LJ_MAX_JSLOTS); 84 lua_assert(J->baseslot >= 1);
85 lua_assert(J->baseslot == 1 || (J->slot[J->baseslot-1] & TREF_FRAME)); 85 lua_assert(J->baseslot == 1 || (J->slot[J->baseslot-1] & TREF_FRAME));
86 lua_assert(nslots < LJ_MAX_JSLOTS); 86 lua_assert(nslots <= LJ_MAX_JSLOTS);
87 for (s = 0; s < nslots; s++) { 87 for (s = 0; s < nslots; s++) {
88 TRef tr = J->slot[s]; 88 TRef tr = J->slot[s];
89 if (tr) { 89 if (tr) {