diff options
| author | Marc André Tanner <mat@brain-dump.org> | 2017-06-01 22:31:23 +0200 |
|---|---|---|
| committer | Marc André Tanner <mat@brain-dump.org> | 2020-02-10 10:06:46 +0100 |
| commit | 6af46f9aa5a2966e5aa93d69d53893b8976918ca (patch) | |
| tree | 7021ec0e181d4f95da7340fe39ecbc71faa19c15 /lua/lexer.lua | |
| parent | c63161e34580080df3f44076449cacd43ab517bc (diff) | |
| download | vis-6af46f9aa5a2966e5aa93d69d53893b8976918ca.tar.gz vis-6af46f9aa5a2966e5aa93d69d53893b8976918ca.tar.xz | |
vis-lua: avoid string memory leaks in error case
The function lua_pushstring can throw an error, meaning it
will setjmp(3) out thereby leaking the allocated memory.
By using lua_newuserdata we let Lua free the memory during
a GC run.
Diffstat (limited to 'lua/lexer.lua')
0 files changed, 0 insertions, 0 deletions
