diff options
Diffstat (limited to 'src/lj_snap.c')
-rw-r--r-- | src/lj_snap.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/lj_snap.c b/src/lj_snap.c index 1c978c26..cc498c89 100644 --- a/src/lj_snap.c +++ b/src/lj_snap.c | |||
@@ -97,7 +97,8 @@ static BCReg snapshot_framelinks(jit_State *J, SnapEntry *map) | |||
97 | { | 97 | { |
98 | cTValue *frame = J->L->base - 1; | 98 | cTValue *frame = J->L->base - 1; |
99 | cTValue *lim = J->L->base - J->baseslot; | 99 | cTValue *lim = J->L->base - J->baseslot; |
100 | cTValue *ftop = frame + funcproto(frame_func(frame))->framesize; | 100 | GCfunc *fn = frame_func(frame); |
101 | cTValue *ftop = isluafunc(fn) ? (frame+funcproto(fn)->framesize) : J->L->top; | ||
101 | MSize f = 0; | 102 | MSize f = 0; |
102 | map[f++] = SNAP_MKPC(J->pc); /* The current PC is always the first entry. */ | 103 | map[f++] = SNAP_MKPC(J->pc); /* The current PC is always the first entry. */ |
103 | while (frame > lim) { /* Backwards traversal of all frames above base. */ | 104 | while (frame > lim) { /* Backwards traversal of all frames above base. */ |