diff options
| author | 2026-02-27 18:18:10 -0600 | |
|---|---|---|
| committer | 2026-02-27 18:19:40 -0600 | |
| commit | 5fec2aa9dfc109e8b95ebfbb61d59018d5739592 (patch) | |
| tree | 409c18570f020dc07282a2c2e5e6a08e41803e9a | |
| parent | Fix GC collecting active fiber during nested janet_continue (#1720) (diff) | |
Move some files around code more defensively for mitigation.
| -rw-r--r-- | src/core/vm.c | 2 | ||||
| -rw-r--r-- | test/c/test-gc-pcall.c (renamed from test/test-gc-pcall.c) | 0 |
2 files changed, 1 insertions, 1 deletions
diff --git a/src/core/vm.c b/src/core/vm.c index 162defd7..1ae82b48 100644 --- a/src/core/vm.c +++ b/src/core/vm.c @@ -1127,11 +1127,11 @@ static JanetSignal run_vm(JanetFiber *fiber, Janet in) { } fiber->child = child; JanetSignal sig = janet_continue_no_check(child, stack[C], &retreg); + stack = fiber->data + fiber->frame; if (sig != JANET_SIGNAL_OK && !(child->flags & (1 << sig))) { vm_return(sig, retreg); } fiber->child = NULL; - stack = fiber->data + fiber->frame; stack[A] = retreg; vm_checkgc_pcnext(); } diff --git a/test/test-gc-pcall.c b/test/c/test-gc-pcall.c index fc37b8ba..fc37b8ba 100644 --- a/test/test-gc-pcall.c +++ b/test/c/test-gc-pcall.c |
