aboutsummaryrefslogtreecommitdiff
path: root/ltm.h
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2020-07-17 14:54:26 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2020-07-17 14:54:26 -0300
commit34affe7a63fc5d842580a9f23616d057e17dfe27 (patch)
tree62283d8c88989180e8e971efe457a8b55afa16a0 /ltm.h
parenta2195644d89812e5b157ce7bac35543e06db05e3 (diff)
downloadlua-34affe7a63fc5d842580a9f23616d057e17dfe27.tar.gz
lua-34affe7a63fc5d842580a9f23616d057e17dfe27.tar.bz2
lua-34affe7a63fc5d842580a9f23616d057e17dfe27.zip
Fixed bug: 'luaD_callnoyield' called twice in a row
In luaD_callnoyield, when there is a possible stack overflow, it zeros the number of CallInfos to force a check when calling the function. However, if the "function" is not a function, the code will raise an error before checking the stack. Then, the error handling calls luaD_callnoyield again and nCcalls is decremented again, crossing the stack redzone without raising an error. (This loop can only happens once, because the error handler must be a function. But once is enough to cross the redzone.)
Diffstat (limited to 'ltm.h')
0 files changed, 0 insertions, 0 deletions