aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authordaurnimator <quae@daurnimator.com>2017-05-23 16:23:49 +1000
committerBenoit Giannangeli <giann008@gmail.com>2017-05-24 10:15:31 +0200
commite7dd3b51548ec0445a448895d52fb60958ce0a16 (patch)
tree9f7f13ce510db322131ef443e16cf640f72cff17 /src
parent85e4964ecc198dad6a9b4f3e179acf80aca2da93 (diff)
downloadfengari-e7dd3b51548ec0445a448895d52fb60958ce0a16.tar.gz
fengari-e7dd3b51548ec0445a448895d52fb60958ce0a16.tar.bz2
fengari-e7dd3b51548ec0445a448895d52fb60958ce0a16.zip
src/ldo.js: Don't want to call user's message handler with a 'this' of CallInfo
Diffstat (limited to 'src')
-rw-r--r--src/ldo.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/ldo.js b/src/ldo.js
index 4ed8380..ab3f197 100644
--- a/src/ldo.js
+++ b/src/ldo.js
@@ -396,7 +396,8 @@ const finishCcall = function(L, status) {
/* finish 'lua_callk'/'lua_pcall'; CIST_YPCALL and 'errfunc' already
handled */
if (ci.nresults === defs.LUA_MULTRET && L.ci.top < L.top) L.ci.top = L.top;
- let n = ci.c_k(L, status, ci.c_ctx); /* call continuation function */
+ let c_k = ci.c_k; /* don't want to call as method */
+ let n = c_k(L, status, ci.c_ctx); /* call continuation function */
assert(n < (L.top - L.ci.funcOff), "not enough elements in the stack");
luaD_poscall(L, ci, L.top - n, n); /* finish 'luaD_precall' */
};