summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLamont Granquist <lamont@scriptkiddie.org>2015-06-22 10:35:27 -0700
committerLamont Granquist <lamont@scriptkiddie.org>2015-06-22 10:35:27 -0700
commitae0fc4161d7fc811d786d95c8f8c2323dcfeb30a (patch)
treeb241173d7137314c6a2bdc2a68c2d36fd83bba02
parent92fe69e4141cc7fca07eb432c5d16791054311d6 (diff)
parent35f286035a3541eb119d91aef8c561456ef2c7e5 (diff)
downloadffi-yajl-ae0fc4161d7fc811d786d95c8f8c2323dcfeb30a.tar.gz
Merge pull request #64 from chef/uninitialized-variable-in-ext
Fix uninitialized instance variable when using ext
-rw-r--r--ext/ffi_yajl/ext/parser/parser.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/ext/ffi_yajl/ext/parser/parser.c b/ext/ffi_yajl/ext/parser/parser.c
index a5d2e9a..c0b8eab 100644
--- a/ext/ffi_yajl/ext/parser/parser.c
+++ b/ext/ffi_yajl/ext/parser/parser.c
@@ -184,6 +184,7 @@ static VALUE mParser_do_yajl_parse(VALUE self, VALUE str, VALUE yajl_opts) {
unsigned char *err;
volatile CTX ctx;
+ rb_ivar_set(self, rb_intern("key"), Qnil);
rb_ivar_set(self, rb_intern("stack"), rb_ary_new());
rb_ivar_set(self, rb_intern("key_stack"), rb_ary_new());