summaryrefslogtreecommitdiff
path: root/cont.c
diff options
context:
space:
mode:
Diffstat (limited to 'cont.c')
-rw-r--r--cont.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/cont.c b/cont.c
index a8321abcca..0c49d34742 100644
--- a/cont.c
+++ b/cont.c
@@ -919,9 +919,7 @@ cont_free(void *ptr)
else {
rb_fiber_t *fiber = (rb_fiber_t*)cont;
coroutine_destroy(&fiber->context);
- if (!fiber_is_root_p(fiber)) {
- fiber_stack_release(fiber);
- }
+ fiber_stack_release(fiber);
}
RUBY_FREE_UNLESS_NULL(cont->saved_vm_stack.ptr);