summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorYukihiro "Matz" Matsumoto <[email protected]>2012-06-02 23:33:56 -0700
committerYukihiro "Matz" Matsumoto <[email protected]>2012-06-02 23:33:56 -0700
commitc9227e44fbbbaed6e6da6fed3dd4c2a1b55b9f72 (patch)
tree4183396beed3668a360e01bdc90f0f46625824e1
parent48ff4f2d36de313591f222708eaf43260a4d39df (diff)
parent5b3628051b975a899082ec25847100ad2b291564 (diff)
downloadmruby-c9227e44fbbbaed6e6da6fed3dd4c2a1b55b9f72.tar.gz
mruby-c9227e44fbbbaed6e6da6fed3dd4c2a1b55b9f72.zip
Merge pull request #236 from liyuray/master
fix an issue that access violation occurred on uninitialized irep block when running "make test" on MINGW.
-rw-r--r--src/state.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/state.c b/src/state.c
index b3946bad9..727bd8ecb 100644
--- a/src/state.c
+++ b/src/state.c
@@ -76,6 +76,7 @@ mrb_add_irep(mrb_state *mrb, int idx)
if (idx > max) max = idx+1;
mrb->irep = mrb_malloc(mrb, sizeof(mrb_irep*)*max);
+ memset(mrb->irep, 0, sizeof(mrb_irep*)*max);
mrb->irep_capa = max;
}
else if (mrb->irep_capa <= idx) {