Skip to content

Commit

Permalink
Apply Lua.org patch
Browse files Browse the repository at this point in the history
Lua does not check GC when creating error messages.

reported by Viacheslav Usov on 06 Jul 2017. existed since 5.3.2.

Example:
    See https://www.lua.org/bugs.html#5.3.4-4.
  • Loading branch information
Vultraz authored and GregoryLundberg committed Nov 30, 2017
1 parent 37eb623 commit f8e401f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/lua/ldebug.cpp
Expand Up @@ -653,6 +653,7 @@ l_noret luaG_runerror (lua_State *L, const char *fmt, ...) {
CallInfo *ci = L->ci;
const char *msg;
va_list argp;
luaC_checkGC(L); /* error message uses memory */
va_start(argp, fmt);
msg = luaO_pushvfstring(L, fmt, argp); /* format message */
va_end(argp);
Expand Down

0 comments on commit f8e401f

Please sign in to comment.