From 6f42ac9cce2ded1f62cf967f42c85b1171678fa1 Mon Sep 17 00:00:00 2001 From: Benoit Giannangeli Date: Fri, 24 Mar 2017 17:10:22 +0100 Subject: Added missing sprintf --- src/lstrlib.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/lstrlib.js') diff --git a/src/lstrlib.js b/src/lstrlib.js index 1294baa..2e623b6 100644 --- a/src/lstrlib.js +++ b/src/lstrlib.js @@ -366,7 +366,7 @@ const str_format = function(L) { concat(b, s); /* keep entire string */ lapi.lua_pop(L, 1); /* remove result from 'luaL_tolstring' */ } else { /* format the string into 'buff' */ - concat(b, s); + concat(b, lua.to_luastring(sprintf(String.fromCharCode(...form), str.jsstring()))); lapi.lua_pop(L, 1); /* remove result from 'luaL_tolstring' */ } } -- cgit v1.2.3-54-g00ecf