Skip to content

Instantly share code, notes, and snippets.

@kazuho
Created January 14, 2016 09:43
Show Gist options
  • Save kazuho/3df214c80b1d0404ab94 to your computer and use it in GitHub Desktop.
Save kazuho/3df214c80b1d0404ab94 to your computer and use it in GitHub Desktop.
diff --git a/lib/handler/mruby.c b/lib/handler/mruby.c
index d7f6266..0a1ceb6 100644
--- a/lib/handler/mruby.c
+++ b/lib/handler/mruby.c
@@ -660,6 +660,8 @@ static void send_response(h2o_mruby_generator_t *generator, mrb_int status, mrb_
return;
}
+ mrb_gc_arena_restore(mrb, gc_arena);
+
/* send the entire response immediately */
if (h2o_memis(generator->req->input.method.base, generator->req->input.method.len, H2O_STRLIT("HEAD"))) {
h2o_start_response(generator->req, &generator->super);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment