Skip to content
Browse files

Zero out the generator struct to avoid GC problems

  • Loading branch information...
1 parent 82f88d9 commit 8e5982d95e0c5aef59b4f05aa8640ae7489f7169 @jakedouglas jakedouglas committed with Evan Phoenix
Showing with 1 addition and 0 deletions.
  1. +1 −0 ext/json/ext/generator/generator.c
View
1 ext/json/ext/generator/generator.c
@@ -616,6 +616,7 @@ static void State_free(JSON_Generator_State *state)
static JSON_Generator_State *State_allocate()
{
JSON_Generator_State *state = ALLOC(JSON_Generator_State);
+ MEMZERO(state, JSON_Generator_State, 1);
return state;
}

0 comments on commit 8e5982d

Please sign in to comment.
Something went wrong with that request. Please try again.