summaryrefslogtreecommitdiff
path: root/cont.c
diff options
context:
space:
mode:
Diffstat (limited to 'cont.c')
-rw-r--r--cont.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/cont.c b/cont.c
index dcbae545845..41519fb048b 100644
--- a/cont.c
+++ b/cont.c
@@ -621,6 +621,7 @@ fiber_setcontext(rb_fiber_t *newfib, rb_fiber_t *oldfib)
/* save oldfib's machine stack */
if (oldfib->status != TERMINATED) {
+ SET_MACHINE_STACK_END(&th->machine_stack_end);
switch (stackgrowdirection) {
case STACK_GROW_DOWNWARD:
oldfib->cont.machine_stack_size = th->machine_stack_start - th->machine_stack_end;