summaryrefslogtreecommitdiff
path: root/src/lbaselib.js
diff options
context:
space:
mode:
authorBenoit Giannangeli <giann008@gmail.com>2017-05-05 15:02:32 +0200
committerBenoit Giannangeli <giann008@gmail.com>2017-05-05 15:02:32 +0200
commit818a86ae8e4afe75f0521967125cdf1cca6b26f0 (patch)
tree16bb704ab9d38cf397276329ca2b86410551648d /src/lbaselib.js
parenta8083c0397a20233866b4f69a3e393d843fb417d (diff)
downloadfengari-818a86ae8e4afe75f0521967125cdf1cca6b26f0.tar.gz
fengari-818a86ae8e4afe75f0521967125cdf1cca6b26f0.tar.bz2
fengari-818a86ae8e4afe75f0521967125cdf1cca6b26f0.zip
Added missing parameter to luaL_loadbufferx in luaB_load
Diffstat (limited to 'src/lbaselib.js')
-rw-r--r--src/lbaselib.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lbaselib.js b/src/lbaselib.js
index 5e3fff6..d1d930a 100644
--- a/src/lbaselib.js
+++ b/src/lbaselib.js
@@ -297,7 +297,7 @@ const luaB_load = function(L) {
let status;
if (s !== null) { /* loading a string? */
let chunkname = lauxlib.luaL_optstring(L, 2, s);
- status = lauxlib.luaL_loadbufferx(L, s, chunkname, mode);
+ status = lauxlib.luaL_loadbufferx(L, s, s.length, chunkname, mode);
} else { /* loading from a reader function */
let chunkname = lauxlib.luaL_optstring(L, 2, lua.to_luastring("=(load)", true));
lauxlib.luaL_checktype(L, 1, lua.LUA_TFUNCTION);