diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2021-01-19 10:03:13 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2021-01-19 10:03:13 -0300 |
commit | 6ccd24eff58340c00db2877c4558a63c6b859442 (patch) | |
tree | 4c8f51657d8d1f4921846a23ba4b475db49fd837 /lstate.h | |
parent | d0f34d91373fa265d4445e456e4a10ce206c1559 (diff) | |
download | lua-6ccd24eff58340c00db2877c4558a63c6b859442.tar.gz lua-6ccd24eff58340c00db2877c4558a63c6b859442.tar.bz2 lua-6ccd24eff58340c00db2877c4558a63c6b859442.zip |
Simpler handling of errors when creating tbc variables
New field 'lua_State.ptbc' keeps to-be-closed variable until its
upvalue is created, so that it can be closed in case of a
memory-allocation error.
Diffstat (limited to 'lstate.h')
-rw-r--r-- | lstate.h | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -308,6 +308,7 @@ struct lua_State { | |||
308 | int basehookcount; | 308 | int basehookcount; |
309 | int hookcount; | 309 | int hookcount; |
310 | volatile l_signalT hookmask; | 310 | volatile l_signalT hookmask; |
311 | StkId ptbc; /* pending to-be-closed variable */ | ||
311 | }; | 312 | }; |
312 | 313 | ||
313 | 314 | ||