[Tarantool-patches] [PATCH luajit 0/2] Snapshot restore with stack overflow

Sergey Kaplun skaplun at tarantool.org
Tue Jun 10 13:28:50 MSK 2025


This patchset fixes the issue with stackoverflow during the snapshot
restoration. The first patch solves the problem in the incorrect way,
since it leads to the uninitalized read. The second patch fixes the
issue correctly.

Branch: https://github.com/tarantool/luajit/tree/skaplun/lj-1196-partial-snap-restore
Related issues:
* https://github.com/LuaJIT/LuaJIT/issues/1196
* https://github.com/tarantool/tarantool/issues/11278
Related ML link: https://www.freelists.org/post/luajit/Invalid-read-found-by-valgrind

Mike Pall (2):
  Handle partial snapshot restore due to stack overflow.
  Different fix for partial snapshot restore due to stack overflow.

 src/lj_snap.c                                 |  3 +-
 .../lj-1196-partial-snap-restore.test.lua     | 51 +++++++++++++++
 ...-1196-stack-overflow-snap-restore.test.lua | 65 +++++++++++++++++++
 3 files changed, 118 insertions(+), 1 deletion(-)
 create mode 100644 test/tarantool-tests/lj-1196-partial-snap-restore.test.lua
 create mode 100644 test/tarantool-tests/lj-1196-stack-overflow-snap-restore.test.lua

-- 
2.49.0



More information about the Tarantool-patches mailing list